diff options
Diffstat (limited to '.config/nvim/lua/settings.lua')
-rwxr-xr-x | .config/nvim/lua/settings.lua | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/.config/nvim/lua/settings.lua b/.config/nvim/lua/settings.lua index ef8fb95..eaa5617 100755 --- a/.config/nvim/lua/settings.lua +++ b/.config/nvim/lua/settings.lua @@ -12,6 +12,8 @@ o.smarttab = true o.number = true o.list = true o.mouse = '' +o.backspace = 'indent,eol,start' + o.swapfile = false @@ -33,12 +35,7 @@ cmd 'filetype indent on' cmd 'colorscheme colorscheme' vim.cmd([[ - au BufNewFile,BufRead *.Dockerfile,Dockerfile.* setlocal filetype=dockerfile au BufNewFile,BufRead *.j2*,*.jinja* setlocal filetype=django - au BufNewFile,BufRead */task/config setlocal filetype=taskrc - au BufNewFile,BufRead *.env* setlocal filetype=sh - - au BufNewFile,BufRead */playbooks/*.yml set filetype=yaml.ansible au BufNewFile,BufRead */.config/neomutt/* \ if &filetype == "" | @@ -46,6 +43,23 @@ vim.cmd([[ \ endif ]]) +vim.filetype.add({ + pattern = { + ['.*playbooks/.*%.yml'] = 'yaml.ansible', + ['.*roles/.*/tasks/.*%.yml'] = 'yaml.ansible', + ['.*roles/.*/defaults/.*%.yml'] = 'yaml.ansible', + ['.*roles/.*/vars/.*%.yml'] = 'yaml.ansible', + ['.*roles/.*/meta/.*%.yml'] = 'yaml.ansible', + ['.*roles/.*/templates/.*%.yml'] = 'yaml.ansible', + ['.*%.Dockerfile'] = 'dockerfile', + ['Dockerfile%..*'] = 'dockerfile', + ['.*%.env.*'] = 'sh', + ['.*/task/config'] = 'taskrc', + ['%.ansible%-lint'] = 'yaml', + ['%.yamllint'] = 'yaml', + } +}) + --[[ require'nvim-treesitter.configs'.setup { textobjects = { |