kryptco / kr

DEPRECATED A dev tool for SSH auth + Git commit/tag signing using a key stored in Krypton.
https://krypt.co/developers/
Other
1.59k stars 109 forks source link

Emacs + TRAMP working with Krypton #252

Closed cro closed 5 years ago

cro commented 5 years ago

I am an Emacs user and have switched to Krypton for my ssh key needs. Since I have done so I am no longer able to get Emacs's TRAMP remote file and shell capabilities working. I suspect it is because of Krypton's console messages. Is there some way to turn them off, ideally just for my Emacs instance?

cro commented 5 years ago

Closing, further investigation revealed problems with my .bashrc. Sorry for the false alarm.

cro commented 5 years ago

Realizing that some folks find answers to their questions in the strangest places, I will post my solution here.

My issue was that I had installed Byobu (the screen / tmux manager) on several remote servers at the same time I had enabled Krypton authentication. Since other one-off commands like ssh <remote-server> ls worked fine, I did not suspect Byobu had broken TRAMP. What I did not realize was that TRAMP and eshell behave like interactive logins. The Emacs TRAMP manual (https://www.gnu.org/software/tramp/#Remote-programs) mentioned that TRAMP sets $TERM to dumb when logging into remote machines, so adding a conditional that does not start Byobu when $TERM=dumb took care of the problem.