Emacs / CVS / OpenSSH: preventing password popup

后端 未结 6 1289
失恋的感觉
失恋的感觉 2021-01-18 01:50

I\'m using GNU Emacs on my Ubuntu netbook in fullscreen mode. When I edit files that are under version control and hit C-x v v to commit the latest changes, an OpenSSH popup

6条回答
  •  星月不相逢
    2021-01-18 02:12

    It's probably the ssh-askpass program kicking in, which I think looks at the DISPLAY environment variable to decide how to request the password. If set, it pops up a graphical window, and if not, it asks the TTY.

    If the vcs subsystem detects when passwords are requested from the user (which is likely), then it's possible that you can unset $DISPLAY for subprocesses:

    (setenv "DISPLAY" nil)
    

    This might have other negative side-effects, though, so also check out "man ssh-askpass" in case something there might help.

    (Disclaimer: I personally use a solution based on ssh-agent, which I strongly recommend.)

提交回复
热议问题