summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIzhak Jakov <izhakjakov>2021-07-03 13:09:37 +0200
committerBram Moolenaar <Bram@vim.org>2021-07-03 13:09:37 +0200
commitacbb4b5720fc27b8b07357b763ed4e5a944ae1da (patch)
treead396a7a7b71fdbcec19f7b74615654c3bd09165
parenta26f56f67502c72d44c61afdede2206cdde47c17 (diff)
patch 8.2.3085: JSONC files are not recognizedv8.2.3085
Problem: JSONC files are not recognized. Solution: Recognize .jsonc files. (Izhak Jakov, closes #8500)
-rw-r--r--runtime/filetype.vim3
-rw-r--r--src/testdir/test_filetype.vim1
-rw-r--r--src/version.c2
3 files changed, 6 insertions, 0 deletions
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index e38bc23de0..952a9a66fa 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -868,6 +868,9 @@ au BufNewFile,BufRead *.json-patch setf json
" Jupyter Notebook is also json
au BufNewFile,BufRead *.ipynb setf json
+" JSONC
+au BufNewFile,BufRead *.jsonc setf jsonc
+
" Kixtart
au BufNewFile,BufRead *.kix setf kix
diff --git a/src/testdir/test_filetype.vim b/src/testdir/test_filetype.vim
index 50293e524d..b0eb4aff61 100644
--- a/src/testdir/test_filetype.vim
+++ b/src/testdir/test_filetype.vim
@@ -260,6 +260,7 @@ let s:filename_checks = {
\ 'jovial': ['file.jov', 'file.j73', 'file.jovial'],
\ 'jproperties': ['file.properties', 'file.properties_xx', 'file.properties_xx_xx', 'some.properties_xx_xx_file'],
\ 'json': ['file.json', 'file.jsonp', 'file.json-patch', 'file.webmanifest', 'Pipfile.lock', 'file.ipynb'],
+ \ 'jsonc': ['file.jsonc'],
\ 'jsp': ['file.jsp'],
\ 'kconfig': ['Kconfig', 'Kconfig.debug', 'Kconfig.file'],
\ 'kivy': ['file.kv'],
diff --git a/src/version.c b/src/version.c
index db88afd8d9..70c1b6b97a 100644
--- a/src/version.c
+++ b/src/version.c
@@ -756,6 +756,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 3085,
+/**/
3084,
/**/
3083,