aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-12-04 17:49:12 +0800
committerGitHub <noreply@github.com>2024-12-04 17:49:12 +0800
commitb079a9d2e76062ee7275e35a4623108550e836a5 (patch)
treee12bd0e779404a977c17fa1107979cc178cf6b5f
parentae93c7f369a174f3d738ab55030de2c9dfc10c57 (diff)
downloadrneovim-b079a9d2e76062ee7275e35a4623108550e836a5.tar.gz
rneovim-b079a9d2e76062ee7275e35a4623108550e836a5.tar.bz2
rneovim-b079a9d2e76062ee7275e35a4623108550e836a5.zip
vim-patch:9.1.0902: filetype: Conda configuration files are not recognized (#31445)
Problem: filetype: Conda configuration files are not recognized Solution: detect '.condarc' and 'condarc' files as yaml filetype. (zeertzjq) closes: vim/vim#16162 https://github.com/vim/vim/commit/876de275cb3affa5910664cc52a5177c214313e8
-rw-r--r--runtime/lua/vim/filetype.lua2
-rw-r--r--test/old/testdir/test_filetype.vim2
2 files changed, 3 insertions, 1 deletions
diff --git a/runtime/lua/vim/filetype.lua b/runtime/lua/vim/filetype.lua
index 5d771c30e9..b4c37dd160 100644
--- a/runtime/lua/vim/filetype.lua
+++ b/runtime/lua/vim/filetype.lua
@@ -1873,6 +1873,8 @@ local filename = {
['.clang-tidy'] = 'yaml',
['yarn.lock'] = 'yaml',
matplotlibrc = 'yaml',
+ ['.condarc'] = 'yaml',
+ condarc = 'yaml',
zathurarc = 'zathurarc',
['/etc/zprofile'] = 'zsh',
['.zlogin'] = 'zsh',
diff --git a/test/old/testdir/test_filetype.vim b/test/old/testdir/test_filetype.vim
index 06ac59de20..5a38f26902 100644
--- a/test/old/testdir/test_filetype.vim
+++ b/test/old/testdir/test_filetype.vim
@@ -886,7 +886,7 @@ func s:GetFilenameChecks() abort
\ 'xslt': ['file.xsl', 'file.xslt'],
\ 'yacc': ['file.yy', 'file.yxx', 'file.y++'],
\ 'yaml': ['file.yaml', 'file.yml', 'file.eyaml', 'any/.bundle/config', '.clangd', '.clang-format', '.clang-tidy', 'file.mplstyle', 'matplotlibrc', 'yarn.lock',
- \ '/home/user/.kube/config'],
+ \ '/home/user/.kube/config', '.condarc', 'condarc'],
\ 'yang': ['file.yang'],
\ 'yuck': ['file.yuck'],
\ 'z8a': ['file.z8a'],