VSCODE使用WSL SSH配置和身份?
我在Windows 10和11上使用WSL2来完成所有SSH的操作,但我希望能够在我的VSCODE中使用WSL的WSL2 SSH Config + Identity + Agent。
看到了一些用以下内容之一的单独的ssh.bat的方法
c:\ windows \ system32 \ wsl.exe bash -login -c ssh%* C:\ Windows \ System32 \ wsl.exe bash -ic'ssh%' C:\ Windows \ System32 \ wsl.exe SSH%
在远程.ssh.path中带有ssh.bat beeing。
我唯一能找到的错误是,但是我很确定它以前有效:
[14:18:34.726]从SSH出现错误 “ c:\用户< user> \ documents \ ssh.bat” enoent [14:18:34.727] 指定的路径“ c:\ users<用户> \ documents \ ssh.bat”不是有效的SSH 二进制
似乎没有任何作用。由于某种原因,它不使用WSL SSH。 有什么想法吗?
I'm using WSL2 on Windows 10 and 11 to do all of my ssh stuff but I'd like to be able to use the wsl2 ssh config + identity + agent from wsl within my VSCode.
Saw some approaches with a seperate ssh.bat with one of the following contents
C:\Windows\system32\wsl.exe bash --login -c ssh %*
C:\Windows\system32\wsl.exe bash -ic 'ssh %'
C:\Windows\system32\wsl.exe ssh %
With the ssh.bat beeing in the remote.SSH.Path.
The only error i could find was this but im pretty sure it worked like this before:
[14:18:34.726] Got error from ssh: spawn
"C:\Users<USER>\Documents\ssh.bat" ENOENT [14:18:34.727] The
specified path "C:\Users<USER>\Documents\ssh.bat" is not a valid SSH
binary
Nothing seemed to work. For some reason it does not use the wsl ssh.
Any Ideas?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这条路
缺少后斜线。应该是
The path
is missing a backslash. It should be