help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sudo command with minibuffer password prompt


From: Steve Revilak
Subject: Re: sudo command with minibuffer password prompt
Date: Wed, 16 Dec 2009 21:39:43 -0500
User-agent: Mutt/1.5.19 (2009-01-05)

From: Nordl?w <per.nordlow@gmail.com>

In both Vanilla Emacs 22 and 23 CVS
 (require 'tramp)
 (shell-command "sudo touch ~/.emacs")
fails with the message
 sudo: no tty present and no askpass program specified

What is missing?

Using M-! and typing "sudo ls" into the minibuffer, I see the same
error message with Emacs 23.1.1 on OpenSuse.  Mac OS X displays a
password prompt in the minibuffer, but the password prompt doesn't
seem to accept focus (emacs 22 and 23).

What I really want to do is to spawn an install using apt-get install
from within emacs.

Try this.

 M-x shell

Then run "sudo apt-get install" from the *shell* buffer.  You should
get a password prompt in the minibuffer.

(FWIW, I thought this was one of the neatest additions in Emacs 22 :)

Steve

Attachment: pgpDWCsE8c3CO.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]