From 5147fbae236247d72fcb433f9a7fda9399ec1e3a Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Sun, 25 Aug 2024 02:21:27 +0200 Subject: nvim: Force filetype for *.h files --- .config/nvim/after/ftdetect/c.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.config/nvim/after') diff --git a/.config/nvim/after/ftdetect/c.vim b/.config/nvim/after/ftdetect/c.vim index 4d22e22..c92c21e 100644 --- a/.config/nvim/after/ftdetect/c.vim +++ b/.config/nvim/after/ftdetect/c.vim @@ -1 +1,2 @@ -autocmd BufRead,BufNewFile *.[ch] setfiletype c +" Vim by default sets *.h files to be cpp, so we need to explicitly override that +autocmd BufRead,BufNewFile *.h set filetype=c -- cgit v1.2.3