Skip to content

Commit a1dcd76

Browse files
Freed-Wuchrisbra
authored andcommitted
patch 9.1.0311: filetype: Some config files are not recognized
Problem: Some config files are not recognized Solution: Add some patterns for chktex, ripgreprc and ctags config files. See: https://www.nongnu.org/chktex/ See: https://github.com/BurntSushi/ripgrep/blob/master/GUIDE.md#configuration-file See: https://docs.ctags.io/en/latest/option-file.html#order-of-loading-option-files closes: #14506 Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu> Signed-off-by: Christian Brabandt <cb@256bit.org>
1 parent 9232554 commit a1dcd76

3 files changed

Lines changed: 12 additions & 1 deletion

File tree

runtime/filetype.vim

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,9 @@ au BufNewFile,BufRead *.cs,*.csx setf cs
308308
" CSDL
309309
au BufNewFile,BufRead *.csdl setf csdl
310310

311+
" Ctags
312+
au BufNewFile,BufRead *.ctags setf conf
313+
311314
" Cabal
312315
au BufNewFile,BufRead *.cabal setf cabal
313316

@@ -327,6 +330,9 @@ au BufRead,BufNewFile *.chai setf chaiscript
327330
" Chatito
328331
au BufNewFile,BufRead *.chatito setf chatito
329332

333+
" Chktex
334+
au BufRead,BufNewFile .chktexrc setf conf
335+
330336
" Chuck
331337
au BufNewFile,BufRead *.ck setf chuck
332338

@@ -1863,6 +1869,9 @@ au BufNewFile,BufRead *.rego setf rego
18631869
" Rexx
18641870
au BufNewFile,BufRead *.rex,*.orx,*.rxo,*.rxj,*.jrexx,*.rexxj,*.rexx,*.testGroup,*.testUnit setf rexx
18651871

1872+
" Ripgrep rc
1873+
au BufNewFile,BufRead {.,}ripgreprc setf conf
1874+
18661875
" R Help file
18671876
if has("fname_case")
18681877
au BufNewFile,BufRead *.rd,*.Rd setf rhelp

src/testdir/test_filetype.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ def s:GetFilenameChecks(): dict<list<string>>
162162
cobol: ['file.cbl', 'file.cob', 'file.lib'],
163163
coco: ['file.atg'],
164164
conaryrecipe: ['file.recipe'],
165-
conf: ['auto.master', 'file.conf', 'texdoc.cnf', '.x11vncrc'],
165+
conf: ['auto.master', 'file.conf', 'texdoc.cnf', '.x11vncrc', '.chktexrc', '.ripgreprc', 'ripgreprc', 'file.ctags'],
166166
config: ['configure.in', 'configure.ac', '/etc/hostname.file', 'any/etc/hostname.file'],
167167
confini: ['/etc/pacman.conf', 'any/etc/pacman.conf', 'mpv.conf', 'any/.aws/config', 'any/.aws/credentials', 'file.nmconnection'],
168168
context: ['tex/context/any/file.tex', 'file.mkii', 'file.mkiv', 'file.mkvi', 'file.mkxl', 'file.mklx'],

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -704,6 +704,8 @@ static char *(features[]) =
704704

705705
static int included_patches[] =
706706
{ /* Add new patch number below this line */
707+
/**/
708+
311,
707709
/**/
708710
310,
709711
/**/

0 commit comments

Comments
 (0)