patch 9.2.0217: filetype: cto files are not recognized

Problem:  filetype: cto files are not recognized
Solution: Detect *.cto as concerto filetype (Jamie Shorten)

Add filetype detection for the Concerto Modelling Language. Concerto
is a schema language by the Accord Project for defining data models
used in smart legal contracts and business networks.

Reference:
Language spec: https://concerto.accordproject.org
Tree-sitter grammar: https://github.com/accordproject/concerto-tree-sitter

closes: #19760

Signed-off-by: Jamie Shorten <jamie@jamieshorten.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Jamie Shorten
2026-03-20 23:03:10 +00:00
committed by Christian Brabandt
parent b3d8a0f349
commit 68f9dedba4
3 changed files with 6 additions and 1 deletions
+3 -1
View File
@@ -3,7 +3,7 @@ vim9script
# Vim functions for file type detection
#
# Maintainer: The Vim Project <https://github.com/vim/vim>
# Last Change: 2026 Mar 19
# Last Change: 2026 Mar 20
# Former Maintainer: Bram Moolenaar <Bram@vim.org>
# These functions are moved here from runtime/filetype.vim to make startup
@@ -1888,6 +1888,8 @@ const ft_from_ext = {
"cr": "crystal",
# CSV Files
"csv": "csv",
# Concertor
"cto": "concerto",
# CUDA Compute Unified Device Architecture
"cu": "cuda",
"cuh": "cuda",
+1
View File
@@ -194,6 +194,7 @@ def s:GetFilenameChecks(): dict<list<string>>
coco: ['file.atg'],
codeowners: ['CODEOWNERS'],
conaryrecipe: ['file.recipe'],
concerto: ['file.cto'],
conf: ['auto.master', 'file.conf', 'texdoc.cnf', '.x11vncrc', '.chktexrc', '.ripgreprc', 'ripgreprc', 'file.ctags'],
config: ['/etc/hostname.file', 'any/etc/hostname.file', 'configure.in', 'configure.ac', 'file.at', 'aclocal.m4'],
confini: ['pacman.conf', 'paru.conf', 'mpv.conf', 'any/.aws/config', 'any/.aws/credentials', 'any/.aws/cli/alias', 'file.nmconnection',
+2
View File
@@ -734,6 +734,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
217,
/**/
216,
/**/