From 3b209dc0f967e469207beea7d6478ebe1e075c76 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Sun, 18 Aug 2024 15:23:47 +0200 Subject: nvim: Prefer *.vim to *.lua --- .config/nvim/after/ftdetect/aerc.vim | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .config/nvim/after/ftdetect/aerc.vim (limited to '.config/nvim/after/ftdetect/aerc.vim') diff --git a/.config/nvim/after/ftdetect/aerc.vim b/.config/nvim/after/ftdetect/aerc.vim new file mode 100644 index 0000000..cdd4812 --- /dev/null +++ b/.config/nvim/after/ftdetect/aerc.vim @@ -0,0 +1,18 @@ +let s:cfg = getenv('XDG_CONFIG_HOME') +if s:cfg == v:null + let s:cfg = '~/.config/aerc/' +else + let s:cfg .= '/aerc/' +endif + +let s:ipaths + \ = s:cfg . '*.conf,' + \ . s:cfg . 'stylesets/*,' + \ . '/usr/share/aerc/*.conf,' + \ . '/usr/share/aerc/stylesets/*' +let s:gpaths + \ = s:cfg . 'templates/*,' + \ . '/usr/share/aerc/templates/*' + +execute 'autocmd BufRead,BufNewFile ' . s:ipaths . ' setfiletype ini' +execute 'autocmd BufRead,BufNewFile ' . s:gpaths . ' setfiletype gotmpl' -- cgit v1.2.3