Skip to content

Commit

Permalink
patch 9.0.2060: *.{gn,gni} files are not recognized
Browse files Browse the repository at this point in the history
Problem:  *.{gn,gni} files are not recognized
Solution: Detect some as gn filetype (without adding an extra filetype)

Those come from: https://gn.googlesource.com/gn/

closes: #13405

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Amaan Qureshi <amaanq12@gmail.com>
  • Loading branch information
amaanq authored and chrisbra committed Oct 23, 2023
1 parent a5a1534 commit 84394f2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions runtime/filetype.vim
Original file line number Diff line number Diff line change
Expand Up @@ -818,6 +818,9 @@ au BufNewFile,BufRead *.gleam setf gleam
" GLSL
au BufNewFile,BufRead *.glsl setf glsl

" GN (generate ninja) files
au BufNewFile,BufRead *.gn,*.gni setf gn

" GP scripts (2.0 and onward)
au BufNewFile,BufRead *.gp,.gprc setf gp

Expand Down
1 change: 1 addition & 0 deletions src/testdir/test_filetype.vim
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,7 @@ def s:GetFilenameChecks(): dict<list<string>>
gkrellmrc: ['gkrellmrc', 'gkrellmrc_x'],
gleam: ['file.gleam'],
glsl: ['file.glsl'],
gn: ['file.gn', 'file.gni'],
gnash: ['gnashrc', '.gnashrc', 'gnashpluginrc', '.gnashpluginrc'],
gnuplot: ['file.gpi', '.gnuplot'],
go: ['file.go'],
Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Original file line number Diff line number Diff line change
Expand Up @@ -704,6 +704,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
2060,
/**/
2059,
/**/
Expand Down

0 comments on commit 84394f2

Please sign in to comment.