Mercurial > vim
changeset 32706:fa80326c0188
Add filetype detection for eyaml files (#12659)
Commit: https://github.com/vim/vim/commit/b69b9d5e175351c9a25507139954f6211f37fdd9
Author: Max Gautier <mg@max.gautier.name>
Date: Wed Aug 9 17:18:36 2023 +0200
Add filetype detection for eyaml files (https://github.com/vim/vim/issues/12659)
https://github.com/voxpupuli/hiera-eyaml/ uses and produces the eyaml
format, which is simply yaml with some encrypted values.
It's convenient to edit the file without decrypting when not touching
encrypted values (or when you don't have access to the decryption key),
which is why vim should treat those files as yaml files.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Wed, 09 Aug 2023 17:30:02 +0200 |
parents | 31b68cad57cc |
children | 0d9aa2e5e9d0 |
files | runtime/filetype.vim src/testdir/test_filetype.vim |
diffstat | 2 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -2544,7 +2544,7 @@ au BufNewFile,BufRead *.yy,*.yxx,*.y++ au BufNewFile,BufRead *.y call dist#ft#FTy() " Yaml -au BufNewFile,BufRead *.yaml,*.yml setf yaml +au BufNewFile,BufRead *.yaml,*.yml,*.eyaml setf yaml " Raml au BufNewFile,BufRead *.raml setf raml
--- a/src/testdir/test_filetype.vim +++ b/src/testdir/test_filetype.vim @@ -799,7 +799,7 @@ def s:GetFilenameChecks(): dict<list<str xsd: ['file.xsd'], xslt: ['file.xsl', 'file.xslt'], yacc: ['file.yy', 'file.yxx', 'file.y++'], - yaml: ['file.yaml', 'file.yml', '.clangd', '.clang-format', '.clang-tidy'], + yaml: ['file.yaml', 'file.yml', 'file.eyaml', '.clangd', '.clang-format', '.clang-tidy'], yang: ['file.yang'], yuck: ['file.yuck'], z8a: ['file.z8a'],