visual-studio-code - 在远程服务器上使用 VSCode 资源管理器(使用 SSH)

标签 visual-studio-code

我需要使用 SSH 在远程服务器中编码/编辑文件,我想使用 VSCode 访问它。

我在 Windows 10 上,在 VSCode 中使用“Git Bash”作为集成终端,这意味着我可以使用 VSCode 的终端连接到服务器。
我缺少的是一种将文件从终端打开到编辑器的方法,甚至更好 - 使用资源管理器与文件进行交互。

如何才能做到这一点?

最佳答案

自 2019 年 5 月 2 日发布“Remote Development with VS Code”以来,您现在正式拥有:

Visual Studio Code Remote - SSH

https://microsoft.github.io/vscode-remote-release/images/ssh-readme.gif

The Remote - SSH extension lets you use any remote machine with a SSH server as your development environment.
Since nearly every desktop and server operating system has a SSH server that can be configured, the extension can greatly simplify development and troubleshooting in a wide variety of situations.

You can:

  • Develop on the same operating system you deploy to or use larger, faster, or more specialized hardware than your local machine.
  • Quickly swap between different, remote development environments and safely make updates without worrying about impacting your local machine.
  • Access an existing development environment from multiple machines or locations.
  • Debug an application running somewhere else such as a customer site or in the cloud.


2020 年第一季度:VSCode 1.42改进了对 Windows 服务器的支持,包括自动操作系统检测。

关于visual-studio-code - 在远程服务器上使用 VSCode 资源管理器(使用 SSH),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47179532/

相关文章:

ubuntu - 如何在 Ubuntu -2021 上更新 VSCode

visual-studio-code - VS Code 中存储的 C++ 默认代码片段在哪里?

regex - 如何使用查找和替换在 vscode 中将所有驼峰式字符串替换为 kebab 式字符串

visual-studio-code - 从 WSL 中选择 Python 解释器

visual-studio-code - 在 VSCode 中切换文档字符串的命令

django - VSCode + 远程开发 + django : avoiding forwarding ports

git - 将选择性提交从 Dev 推送到 Prod 分支

php - 无法在 Visual Studio Code 上设置断点

visual-studio-code - VS Code 的选项卡组

visual-studio-code - VS Code 终端上的透明光标