From: Glenn Morris Date: Tue, 23 Oct 2007 07:10:56 +0000 (+0000) Subject: Chris Moore X-Git-Tag: emacs-pretest-22.1.90~539 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a6151b2c1070058fcdc9cf9021e331c1f563bc1d;p=emacs.git Chris Moore (comint-password-prompt-regexp): Handle `[sudo] password'-style prompt. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cb4029e1da7..7731ffa3dbf 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2007-10-23 Chris Moore + + * comint.el (comint-password-prompt-regexp): + Handle `[sudo] password'-style prompt. + 2007-10-23 Glenn Morris * progmodes/f90.el (f90-do-indent, f90-if-indent) diff --git a/lisp/comint.el b/lisp/comint.el index 80a42dbdbfa..ed1f38bf1a1 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -334,10 +334,11 @@ This variable is buffer-local." ;; ksu prints a prompt like `Kerberos password for devnull/root@GNU.ORG: '. ;; ssh-add prints a prompt like `Enter passphrase: '. ;; plink prints a prompt like `Passphrase for key "root@GNU.ORG": '. +;; Ubuntu's sudo prompts like `[sudo] password for user:' ;; Some implementations of passwd use "Password (again)" as the 2nd prompt. (defcustom comint-password-prompt-regexp "\\(\\([Oo]ld \\|[Nn]ew \\|'s \\|login \\|\ -Kerberos \\|CVS \\|UNIX \\| SMB \\|LDAP \\|^\\)\ +Kerberos \\|CVS \\|UNIX \\| SMB \\|LDAP \\|\\[sudo] \\|^\\)\ \[Pp]assword\\( (again)\\)?\\|\ pass phrase\\|\\(Enter \\|Repeat \\|Bad \\)?[Pp]assphrase\\)\ \\(?:, try again\\)?\\(?: for [^:]+\\)?:\\s *\\'"