-
Notifications
You must be signed in to change notification settings - Fork 847
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
NT path is not available in SSH #2145
Comments
@poma - Good suggestion, an easy way for users to convert NT->LX and LX->NT paths has come up a few times. Your idea of a virtual file is an interesting idea. |
You could expose the registry entries in
That would be interesting idea. [Heck, it would be "interesting" if the whole registry tree were a read/write filesystem under But using the registry for WSL's definition of
"That ain't right". Nor is |
I don't understand how the addition of WSLENV fix this problem. Do I have to add some sort of injection of |
From my point of view, WSLENV doesn't help here as WSLENV is itself not set if the shell is started via ssh. One could argue to define WSLENV in some shell startup files, but that would only work for (wsl->cmd) and not the other way round... A WSL login shell shouldn't behave differently for
e.g
or
should behave the same |
You're right, actually. It doesn't. This issue went sideways on OP second paragraph "Maybe better approach would be to somehow expose Windows variables". The approach taken was The title and first paragraph of the OP, meanwhile, was about |
Getting back to the topic of the title "NT path is not available in SSH", in #4911 the example was
We definitely can access to any command in NT using the full path of course. The behavior I'd expect would be to use all environment as if Do you have any suggestion on repeating this injection. Maybe it should be a command in |
That would be an unusual thing to expect, since the WSL, for its part, knows nothing of either
Yes, in the first reply of #4911 which is still open (or at least, not quite dead yet). Contrast this closed issue, which was a request to quoth: "somehow expose Windows variables (/proc, syscall, whatever)". Which for better or for worse, addressed with |
I currently run a background ssh server (dropbear) at Windows startup and to use Bash I use Putty that connects to localhost. In my case NT Path variable is not imported in Ubuntu. Looks like currently Path is somehow hard-injected at wsl startup and is not very flexible.
Maybe better approach would be to somehow expose Windows variables (/proc, syscall, whatever) and then have a small user script that appends path to current environment at startup so that users can customize how and when it is appended?
The text was updated successfully, but these errors were encountered: