-
Notifications
You must be signed in to change notification settings - Fork 540
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Honor terminal.integrated.shellArgs #2282
Comments
I believe that if you set the correct paths in |
This is correct, I have checked both variants. However, the
I wonder why that is. Isn't that the purpose of the |
This comment has been minimized.
This comment has been minimized.
Thanks - this looks like some work, will do over the weekend! |
Please notify if any progress. |
Preliminary questions [Required]Disable all the other extensions except for LaTeX Workshop, and check that you still see this issue. [Required]You still see this issue?: N/A (I do need Remote SSH) Make sure to visit the wiki FAQ before filling an issue.You visited the wiki?: Yes If your issue is with compiling a document (not having to do with finding the root file of a project), check first that you can compile manually.You can compile a TeX document manually?: Yes Describe the bug [Required]See above - there is no LatTeX-global PATH setting that I can use, and LaTeX Workshop does not allow me to use interactive/login shell which are the usual way through which I configure my PATHs. You can also formulate this issue differently: The environment variables seen by build tasks and the integrated console are different, and there is no way to make them the same. To ReproduceSteps to reproduce the behavior:
Expected behaviorLaTeX workshop should be able to find the binaries, too, but it does not. Logs [Required]Please paste the whole log messages here, not parts of ones. The log should start with LaTeX Workshop Output [Required]
Developer Tools Console [Required]
ScreenshotsI think this sums it up nicely: Desktop [Required]
Additional questionsAre you using VSCodium?No Are you using LaTeX Workshop with VS Code Remote?Yes If the answer is Yes, please write which one you are using. Write the versions of the remote extension.
Additional contextAdd any other context about the problem here. |
@tamuratak Done. |
Adding one more thing: I can (currently) run a task like this in
So even "Tasks" find the binary. My environment must be configured correctly, but LaTeX workshop is not reading it correctly. |
Please paste the log when you executed the build command of LaTeX and it failed. The current one is useless. |
@tamuratak here you go. I'm surprised to see the correct
|
How about stopping using |
Wow, it seems that has helped. I'll report back if it does not work long-term, but if I don't, this information might be a good candidate for the FAQ. |
Is your feature request related to a problem? Please describe.
I'm always frustrated when I use LaTeX-Workshop with Remote SSH into my Linux system. I (have to) use bash as a shell on that system (
zsh
is not installed). I have set up$PATH
in.bashrc
,.bash_profile
,.profile
, and whatnot. In the terminal,latexmk
works.latexindent
works. But in order to make these commands work for LaTeX-Workshop, a lot of environment-variable gymnastics is required for each individual command. (I have not been able to achieve that forlatexindent
, yet: I have been able to setlatex-workshop.latexindent.path
, but that does not set the Perl library path, obviously.) There does not see to be an equivalent of.zshenv
in bash (which is always called, regardless of whether the shell is login/interactive, compare https://github.com/James-Yu/LaTeX-Workshop/wiki/FAQ#environment-variables-in-zshrc-dont-take-effect-with-vs-code-remote).Describe the solution you'd like
I can set
and this is honored by this task, for example:
When run without
terminal.integrated.shellArgs.linux
, this task prints the default, non-working$PATH
. When run withterminal.integrated.shellArgs.linux
set to-i
/-l
, the correct, working$PATH
set by.bashrc
/.bash_profile
is printed.Additional context
From https://github.com/James-Yu/LaTeX-Workshop/wiki/Install#setting-path-environment-variable:
I feel this is incorrect. (It may apply to local installations, where the
$PATH
is inherited by from local VS Code. This is not the case with Remote SSH. My system and the server are set up correctly. The terminal and tasks findlatexmk
- it's just that LaTeX-Workshop ignoresterminal.integrated.shellArgs.*
(probably because it does not even use a shell if I am not mistaken).My proposal: use a shell, add shellArgs with
cs.spawn
, for example, here:LaTeX-Workshop/src/providers/latexformatter.ts
Line 164 in 2ad71ef
Maybe like this, where
"/bin/bash -i"
is fromterminal.integrated.shell(Args)
:The text was updated successfully, but these errors were encountered: