Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I use a bash shell in emacs (M-x shell) when I am trying to connect restart a GNU screen session (on a remote ssh connection)? When I try it, I get:

avilella@remote-machine-002~$ bash
avilella@remote-machine-002 ~ > screen -RD
Clear screen capability required.

If I try it on a bog-standard terminal, I can restart the same screen session without a problem.

share|improve this question
add comment

1 Answer 1

up vote 2 down vote accepted

I'd say 'good luck'. From what I remember, and what I just tried, emacs does not handle full terminal support under the shell command. For example, in an emacs shell, I try:

$ less /etc/hosts
WARNING: terminal is not fully functional
/etc/hosts (press RETURN)

Then less begins to act like it is a dumb terminal (TERM=dumb less /etc/hosts from a regular terminal).

I'm sure that you can set terminal settings inside emacs using elisp, but that doesn't mean that the shell applet will honor them.

share|improve this answer
    
An Emacs shell buffer does not use a pseudo-terminal, so I agree with @Arcege here. You may have some luck using the terminal-emulator command, which does allocate a pty. –  Fran May 30 '12 at 17:13
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.