I now use vimtex to edit my latex source files.
Usually, I use the xelatex engine.
So I have the following line at the beginning of my
% !TeX program = xelatex
Sometimes I need to switch the engine. I think it is not very convenient to edit this line and reload vim every time when switch the engine.
Are there some method, e.g.
\lua, to make vimtex to switch the engine to pdflatex or lualatex dynamically?
Any suggestion is welcome. Thank you very much!