This question is a follow-up to Switching to the local directory after loading a file?
I have the following in my
autocmd BufReadPost *.tex lchdir %:p:h
with the intent of setting the current directory to the same as the edited file for
*.tex files, without setting the global
It works if I call:
Look at the full filename in status line here:
But it does not work if I call:
gvim --servername desktop_0 --remote-tab-silent /home/romano/education/IntroEle-SAP-135/Lab-T1/LabTestExample.tex
(the culprit seems to be the
--remote-tab-silent switch). How can I correct this so that the
autocmd works in the two cases?