-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.vimftd.vim
More file actions
38 lines (33 loc) · 2.14 KB
/
.vimftd.vim
File metadata and controls
38 lines (33 loc) · 2.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
augroup filetypedetect
autocmd BufNewFile,BufRead *.hy,*.lfe setlocal filetype=lisp
autocmd BufNewFile,BufRead *.pp setlocal filetype=ruby
autocmd BufNewFile,BufRead *.{tf,tfvars} setlocal filetype=terraform syntax=hcl
autocmd BufNewFile,BufRead *.{avsc,tfstate} setlocal filetype=json
autocmd BufNewFile,BufRead Jenkinsfile setlocal filetype=groovy
autocmd BufNewFile,BufRead Dockerfile.* setlocal filetype=dockerfile
autocmd BufNewFile,BufRead master,roster,*.sls setlocal filetype=yaml
autocmd BufNewFile,BufRead */Library/Preferences/pnpm/rc setlocal filetype=dosini
autocmd BufNewFile,BufRead */com.mitchellh.ghostty/config setlocal filetype=dosini
autocmd BufNewFile,BufRead *.{cfg,cnf,coveragerc,sentryclirc,service,terraformrc,tigrc,timer},cqlshrc,{krb5,pip,spark-defaults,supervisord}.conf,.{scalafmt,scalafix}.conf,.bandit,.iredisrc setlocal filetype=dosini
autocmd BufNewFile,BufRead *{requirements,constraints}*.txt setlocal filetype=conf
autocmd BufNewFile,BufRead .{continue,docker,helm,rg}ignore setlocal filetype=gitignore
autocmd BufNewFile,BufRead .gitconfig.* setlocal filetype=gitconfig
autocmd BufNewFile,BufRead .{,*}rules setlocal filetype=markdown
autocmd BufNewFile,BufRead .env{,.*} setlocal filetype=dosini
autocmd BufNewFile,BufRead *.cql setlocal filetype=sql
autocmd BufNewFile,BufRead *.bats setlocal filetype=sh
autocmd BufNewFile,BufRead *.tcss setlocal filetype=css
autocmd BufNewFile,BufRead *.j2 setlocal filetype=jinja
" pyx (implementation) and pxd (definition) are handled, but pxi (include) are not
autocmd BufNewFile,BufRead *.pxi setlocal filetype=pyrex
function! HelmSyntax()
setlocal filetype=yaml
unlet b:current_syntax
syntax include @GO syntax/go.vim
let b:current_syntax = 'yaml'
syntax region goTxt matchgroup=goTpl start=/{{\(-\)\?/ end=/\(-\)\?}}/ contains=@GO containedin=ALLBUT,goTxt
highlight link goTpl PreProc
endfunction
autocmd BufNewFile,BufRead */templates/*.yaml,*/templates/*.tpl call HelmSyntax()
autocmd BufNewFile,BufRead */.ssh/config.* setlocal filetype=sshconfig
augroup END