![]() ![]() ![]() The Linux root file system / is a folder somewhere in the AppData folder where the WSL-Distribution is installed. ![]() Since "/C:" is a symlink to "/mnt/c", emacsclient runs finally on the file "/mnt/c/path/to/file.tex" which is the WSL equivalent of the Windows file "C:\path\to\file.tex". I add a slash in the front so that emacsclient gets called on the path "/C:/path/to/file.tex". Therefore, if %f = "C:\path\to\file.tex" then "$(echo '%f' | tr \\\\ /)" will be replaced by "C:/path/to/file.tex". The $(.) will be replaced by this result in the command line. "echo '%f'" just prints the file name to stdin of the part "tr \\\\ /" behind the vertical bar and "tr \\\\ /" replaces each backslash in stdin with a forward slash and writes the result to stdout. The double escape could be also necessary because I think the command-line is interpreted twice by bash (the Linux shell), the syntax $(.) runs the inner command in a subshell and puts the result of the command in the outer command-line. I don't know if wsl.exe spans a cmd.exe terminal window when called from Windows, but I could imagine that a solution with runHidden.vbs is possible. Wsl.exe controlls the Windows Subsystem for Linux distributions and allows to run a command in them from Windows (or from cmd.exe). Thank you for your deep look into the topic. Note Using Emacs for Windows I have not seen this problem arise since the reverse call is handled by emacsclientW which always worked for me. The issue arises within synctex since it was designed MAINLY FOR MAC then adapted for UNIX OR WINDOWS but NOT A MIX I am unsure if the syntax update addresses the differences**** and in effect the ROOT (pun intended) of the problem is within the control of the source editor (in this case the TeX add-ins to Emacs.) The consequence of that is that you CAN use SumatraPDF windows as a "previewer" but it should be the standard "release version" (portable or installed" that canNOT add comment s or otherwise corrupt the PDF file related to #1026Īlso obsolete #841 since that is now superseded by version 2020 OR run an inverse.vbs Wscript to accept the windows parameters and convert them to nix before calling wsl.exe Then the bash script converts parameters into its own terms Wsl.exe bash.sh +%l "dosfilename" (where dosfilename is "%f") Under the circumstances it would perhaps be worth using a windows to linux shim file ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |