并非什么新鲜的功能,Emacs 早就支持了,不存在「跟进」说法。
远程编辑都是这个套路,也就是需要在远程环境安装并启动过一个 server/client,然后 forwading 回本地电脑,类似远程桌面:
看 vscode 给出的快捷 ssh 配置范例:
Host example-remote-linux-machine-with-identity-file
User your-user-name-on-host
HostName another-host-fqdn-or-ip-goes-here
IdentityFile ~/.ssh/id_rsa-remote-ssh
跟我在 Emacs 的配是一样的:
Host foo
Hostname <remote-ip>
User root
IdentityFile ~/.ssh/foo
ControlMaster auto
ControlPath ~/.ssh/foo.sock
RemoteForward 9999 localhost:9999
远程编辑的最基本的要求就是: 允许在远程环境安装和运行 clinet / server
对于 Emacs 来说就是在远程安装一份 Emacs,对于 VSCode 来说似乎在远程安装一个单独的 cod-insiders
。
跟远程桌面一样,远程编辑就是把本地的操作(打字,快捷键,命令)发往远程电脑执行。所以,你想要用 LSP 补全,也必须在远程安装相应的 LSP 服务端,想要做静态分析,也必须在远程安装 lint。
如果你的远程环境很古老,远程编辑也救不了你。
相关讨论:
3 个赞