ssh通过emacs shell? [英] ssh through emacs shell?

查看:120
本文介绍了ssh通过emacs shell?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道有没有人通过emacs shell使用ssh。我可以连接远程机器,但是我无法使用emacs打开文件来查看/编辑使用'emacs文件名'作为'终端类型'愚蠢的不够强大到可以运行emacs'(通常情况下emac会在控制台内打开通过终端连接)。

I wonder if anyone out there uses ssh through the emacs shell. I am able to connect with the remote machine but I cannot open files to view/edit with emacs using 'emacs filename' as the 'Terminal type "dumb" is not powerful enough to run emacs' (normally emacs would open within the console when connecting through the terminal).

这是一个坏主意,尝试以这样的方式使用emacs,或者这可能有一些修复?非常感谢!

Is this a bad idea to try to use emacs in such a way, or is this possible with a few fixes? Thanks much!

推荐答案

几个想法


  • 通过显式地导出.bashrc。 〜/ .bashrc 和/或重新排列您的bash init文件和〜/ .profile ,以便它在emacs shell内加载;然后在Emacs shell中运行 ssh 正常工作

  • 使用emacs特定的 Tramp mode 通过本地Emacs中的ssh访问远程文件 - 如果您只需要更新/触摸/编辑远程文件即可不需要在本地emacs内部的ssh会话内部打开远程emacs。

  • Source the .bashrc explicitly via . ~/.bashrc and/or rearrange your bash init files and ~/.profile so that this gets loaded inside the emacs shell; then running ssh inside the Emacs shell works just fine
  • Use the emacs-specific Tramp mode to access remote files via ssh inside your local Emacs -- this is useful if you just need to update/touch/edit a remote file so you would not need to open a remote emacs inside the ssh session started from inside your local emacs.

这篇关于ssh通过emacs shell?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆