I have a weird issue in emacs with TRAMP
. i can ssh via M-x ssh to a machine (zlap) from within emacs with no issue. yet when i try to use C-x C-f (find file) it hangs after i enter the passphrase. looking at the message buffer i see this:
Tramp: Opening connection for 132.72.154.204 using ssh...
Tramp: Sending command ‘exec ssh -o ControlMaster=auto -o ControlPath='tramp.%C' -o ControlPersist=no -e none 132.72.154.204’
Tramp: Waiting for prompts from remote shell...
Timeout reached, see buffer ‘*tramp/ssh 132.72.154.204*’ for details
Tramp: Waiting for prompts from remote shell...failed
Tramp: Opening connection for 132.72.154.204 using ssh...failed
Tramp: Opening connection for 132.72.154.204 using ssh...
Couldn’t find local shell prompt for /bin/sh
Tramp: Opening connection for 132.72.154.204 using ssh...failed
tramp-file-name-handler: Couldn’t find local shell prompt for /bin/sh
Invalid face reference: quote [21 times]
looking at the ‘tramp/ssh 132.72.154.204’ buffer shows this
tramp_exit_status 0
$fg[magenta]zeltak$reset_color$fg[cyan]@$reset_color$fg[yellow]zx1voics$reset_color$fg[red]:$reset_color$fg[cyan]~$reset_color$fg[red]|$reset_color$fg[cyan]⇒$reset_color #$
im at loss here, any clue how to resolve this?
(setq tramp-shell-prompt-pattern "\\(?:^\\|\r\\)[^]#$%>\n]*#?[]#$%>].* *\\(^[\\[[0-9;]*[a-zA-Z] *\\)*")
in my ~/.emacs solved it, as explained here: https://www.emacswiki.org/emacs/TrampMode#toc12. – user30747 Oct 26 '18 at 21:06