I use vimtex plugin for writing tex documents in vim8. I added custom hilight for sections in my .vimrc like so:
autocmd FileType tex :syntax match texSectioning "\\section.*"
texSectioning is defined in my color scheme file in
It works on any file with
.tex extension except for one! Copying/movig the file to different dir or/and changing name, changing file extention to
.txt and then manually switching on tex filetype does not help. Even typing
syntax match texSectioning "\\section.*"
command has no effect. There is no
.swp file, I didn't use
mkview (there is no
view folder in .vim), I didn't use sessions.
I'm really confused by this...
the output of
set filetype is
filetype=tex. The standard syntax highlighting works, I'm only missing he custom one.
.latexmkrc solved the problem.
There must have been some interference between
latexmk, but it is wierd if that was the case...