diff options
Diffstat (limited to '.config')
-rw-r--r-- | .config/nvim/after/ftdetect/aerc.lua | 24 | ||||
-rw-r--r-- | .config/nvim/after/ftdetect/llvm.lua | 6 | ||||
-rw-r--r-- | .config/nvim/after/ftdetect/oryx.lua | 6 | ||||
-rw-r--r-- | .config/nvim/after/ftplugin/oryx.lua | 1 |
4 files changed, 37 insertions, 0 deletions
diff --git a/.config/nvim/after/ftdetect/aerc.lua b/.config/nvim/after/ftdetect/aerc.lua new file mode 100644 index 0000000..c430e33 --- /dev/null +++ b/.config/nvim/after/ftdetect/aerc.lua @@ -0,0 +1,24 @@ +local confhome = vim.fn.getenv('XDG_CONFIG_HOME') +confhome = confhome == vim.NIL and '~/.config/aerc/' or confhome .. '/aerc/' + +vim.api.nvim_create_autocmd({'BufRead', 'BufNewFile'}, { + pattern = { + confhome .. '*.conf', + confhome .. 'stylesets/*', + '/usr/share/aerc/*.conf', + '/usr/share/aerc/stylesets/*', + }, + callback = function() + vim.bo.filetype = 'ini' + end, +}) + +vim.api.nvim_create_autocmd({'BufRead', 'BufNewFile'}, { + pattern = { + confhome .. 'templates/*', + '/usr/share/aerc/templates/*', + }, + callback = function() + vim.bo.filetype = 'gotmpl' + end, +}) diff --git a/.config/nvim/after/ftdetect/llvm.lua b/.config/nvim/after/ftdetect/llvm.lua new file mode 100644 index 0000000..6313b3d --- /dev/null +++ b/.config/nvim/after/ftdetect/llvm.lua @@ -0,0 +1,6 @@ +vim.api.nvim_create_autocmd({'BufRead', 'BufNewFile'}, { + pattern = '*.ll', + callback = function() + vim.bo.filetype = 'llvm' + end, +}) diff --git a/.config/nvim/after/ftdetect/oryx.lua b/.config/nvim/after/ftdetect/oryx.lua new file mode 100644 index 0000000..c3647c5 --- /dev/null +++ b/.config/nvim/after/ftdetect/oryx.lua @@ -0,0 +1,6 @@ +vim.api.nvim_create_autocmd({'BufRead', 'BufNewFile'}, { + pattern = '*.yx', + callback = function() + vim.bo.filetype = 'oryx' + end, +}) diff --git a/.config/nvim/after/ftplugin/oryx.lua b/.config/nvim/after/ftplugin/oryx.lua new file mode 100644 index 0000000..984111a --- /dev/null +++ b/.config/nvim/after/ftplugin/oryx.lua @@ -0,0 +1 @@ +vim.bo.commentstring = '/* %s */' |