【问题标题】:M-x compile on remote serverM-x 在远程服务器上编译
【发布时间】:2011-07-04 13:47:35
【问题描述】:

我在 Windows 7 上运行 GNU Emacs,并在 Linux 编译服务器上通过 ssh 进行编译。

emacs 能否与打开的 SSH shell 通信并在其中运行 Make

如果可能的话,我不想每次Make时都打开一个新的shell。

【问题讨论】:

  • 通过 SSH 运行 emacs 怎么样?这是一个选择吗?
  • 没有。我需要定期编辑本地文件。

标签: shell emacs compilation


【解决方案1】:

我最近将此添加到我的 /etc/ssh/ssh_config。

Host server.somewhere.org
  ControlMaster auto
  ControlPath /tmp/%r@%h:%p

此处的 server.somewhere.org 应替换为您的 Linux PC。 它极大地加速了 Emacs TRAMP,因为 SSH 握手只进行一次(当 Emacs 首次连接时)。

这可能在 Windows 中也是可能的。

【讨论】:

  • 谢谢。我想避免每次编译时都重新连接,因为构建系统需要它自己的初始化。无论如何,我都赞成有用。
【解决方案2】:

【讨论】:

  • 看起来很有趣,但不起作用,因为我正在编辑共享网络驱动器上的文件。是否有与 Windows 上的 Emacs 兼容的 ssh 实现?我使用的是 Cygwin 的 ssh,但我不想在 Cygwin 下重新安装 Emacs。
  • 从头开始。 plink.exe 自带 putty。
猜你喜欢
  • 2013-08-12
  • 1970-01-01
  • 2017-05-24
  • 2014-04-05
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多