Open urob opened 12 years ago
To avoid a misunderstanding, latexmk itself is working seamlessly using newer versions of Miktex. It's just the wrappers in this script that need to be adjusted.
Yeah I noticed that too. And debug is not easy since all the window close so fast you can't read anything. I'll try to work on it thought. Keep me updated if you have more clue. We need to include the LICENSE too, I'll try to remind David if he has not done it til now.
The problem with the fast closing windows can be circumvented by temporarily deleting the "silent" in front of the functions calling the compiler (line 85 in latexmk.vim).
There are apparently more than one problem that need to be addressed. The first one, which is easy to fix is that piping to /dev/null cannot be interpreted by the windows cmd. I just ended up deleting ">&/dev/null" in all the commands.
After this is fixed, I get the following error: "The system cannot find the file specified".
To narrow down this mistake further, I changed line 85 to just execute only the first part of the function (vimsetpid). Running this call to the VIM server, I still get the same mistake. One can replicate by typing on the command line:
( "C:\Program Files (x86)\Vim\vim73\gvim.exe" --server GVIM1 --remote-expr '
From here on, I am pretty much stuck. I tried deleting "
Seems like many things are not accepted within cmd.exe, even with msys/mingw support. There is actually a call to ps
with an option that is unrecognised, a cmd1; (cmd2); cmd3
where the parenthesis creates problems.
I don't think the project were intended to be used on win. I created a branch for win32-dev and will try some things.
Also, I think that there is use of some bashism like $$ and $? that are not understandable in win32 environment.
I know this is an old issue, but how did this end?. I'm interested in using this plugin on Windows and I'm now facing the same problem.
Thanks
No progress. I have a lot of work at the moment.
Status update:
C:\Users\mvyonline>sh -c 'gvim.exe --servername GVIM --remote-expr "<SNR>34_LatexmkSetPID"\(\"These\",`echo $$`\)'
Fails to display the correct PID. Pops a error box saying : 0
I want to use this under Windows too. Been experiencing the same issues. I've tweaked the parameter send to cmd a bit and ended up with this:
C:\Windows\system32\cmd.exe /c (gvim.exe --servername GVIM1 --remote-expr "
It seems to work, but generates an error saying "E449: Invalid expression received: Send expression failed." Any ideas how to fix this?
P.S. BTW, on Windows parenthesis does work, but you need to separate commands with '&' instead of semicolon.
Works for me. Only the async option is broken ("Compiling to PDF..." is displayed but nothing happens). When I replace !start /b
with !start /min
in latexmk.vim:265
, it works too.
Feel free to open a pull request. Since I don't use vim on windows, I am not able to test.
I would have to try to reproduce this on another machine since it could eaily be a configuration issue/installation problem on my side.
I was on the same boat and confirmed the findings by @Oberon00: disabling g:LatexBox_latexmk_async
or replacing !start /b
with !start /min
in ftplugin/latex-box/latexmk.vim:270
solves the problem. However, neither solution is flawless: the former solution disables the useful async compiling and the latter will keep a terminal window (minimized) on the taskbar.
Environment: Windows 7 SP1 64-bit, VIM 7.4.589 64-bit, latest version of LaTeX-Box.
Currently the calls to latexmk and the viewer don't seem to work on Windows. Not sure whether that is something that can be fixed easily. I am hoping to find some time to look into that myself, but maybe you can give me a few hints what kind of adjustments would be necessary and which functions are affected. Great plugin otherwise! Would like to be able to use it for my work.