annaplans.blogg.se

Ubuntu webstorm
Ubuntu webstorm






ubuntu webstorm

zshrc, you can then add \\wsl$\Ubuntu\home\(username)\.cargo\bin to the Windows $env:Path using the Environment Variable window. In the end, what I did was manually adding each needed $PATH of WSL into the Windows PATH.įor example, if there was export PATH=$PATH:home/(username)/.cargo/bin in. The opposite doesn't work, probably because the PATH in WSL should not interfere with Windows.I've tried adding the $PATH of WSL into $WSLENV but it didn't seem to work. The Windows PATH is shared to WSL by default.

ubuntu webstorm

Setting the PATH in Windowsįor most environment variables, the previous method works well. When you run or debug any of the Run/Debug Configurations, you will see that the environment variable is shared successfully. Run WebStorm from the PowerShell that was just created.You can check if it worked well by running the below command after you've run the above. zshrc was sourced and therefore $WSLENV set as well. Although this doesn't seem to achieve anything, by going through zsh in WSL. This runs WSL using zsh (logged-in and interactive), then runs powershell which brings you back to Windows. # And for some reason, appending the variable after $WSLENV didn't work well zshrc so that it sets $WSLENV when zsh starts.Įxport WSLENV=VAR_I_WANT_TO_SHARE:$WSLENV Sharing WSL's environment variable to Windows through WSLENV There are two ways to solve the problem as follows. (Thank you, and main problem is that WebStorm is installed on Windows and therefore knows only the environment variables in Windows. Thanks to the answer here and the discussion below, I was able to figure it out. Yes, this violates DRY (don't repeat yourself), but it's probably the best route.

ubuntu webstorm

it would help me a lot to know what is the best practice in such situations.īest practice is probably to make sure that your ~/.profile has any environment changes needed. I would assume that WebStorm is executing the shell as a non-interactive one, which means that it wouldn't even parse ~/.bashrc if Bash was your default shell. I'm guessing you would need these set in a. It might be worth trying to specify Zsh in those settings, but again, I can't be sure.Īnd my environment variables and PATH are all set in. Maybe answer (or another) will cover it for you, but if it doesn't, I'm noticing this doc page. I don't run WebStorm myself, so I'm not sure on this exactly. When using Run/Debug Configurations it uses the default non-interactive shell, which is dash as far as I know If you select "No" in the resulting dialog, then the system will be updated to point /bin/sh to bash instead of dash. It is possible in Ubuntu to change the default non-interactive ("system" shell) from Dash to Bash with sudo dpkg-reconfigure dash. While Zsh might be compatible with 99.9% of them, eventually there's a strong likelihood that some difference in Zsh would cause a system-level script to fail (or at least produce results inconsistent with those from Dash). So many built-in scripts rely on /bin/sh pointing to Dash, or at least Bash. Well, maybe (using symlinks), but it would be a really bad idea.

ubuntu webstorm

There are several questions and points you make:įirst, from the question title (and the summary at the end):Ĭan I use zsh as the default non-interactive shell for WSL2 Ubuntu?








Ubuntu webstorm