From: Thierry Volpiatto <thierry.volpiatto@gmail.com>
To: bug-gnu-emacs@gnu.org
Subject: bug#6226: Please add a customizable option to NOT call tramp for every sudo command
Date: Wed, 26 May 2010 07:55:16 +0200 [thread overview]
Message-ID: <874ohvjjgb.fsf@tux.homenetwork> (raw)
In-Reply-To: <AANLkTin_Iox09KQBhxpnKCpG71T-lf41cwgYt9CCCGDB@mail.gmail.com>
Michael Albinus <michael.albinus@gmx.de> writes:
> Stefan Monnier <monnier@iro.umontreal.ca> writes:
>
>>> fmakunbound does the job, yes. But i just think providing a defcustom
>>> interface
>>
>> Agreed.
>
> I don't know, whether another defcustom is needed. Eshell gives you
> already configuration hooks, for example:
>
> (add-hook 'eshell-named-command-hook
> (lambda (command args)
> (if (member command '("su" "sudo"))
> (throw 'eshell-replace-command
> (eshell-parse-command (concat "*" command) args)))))
>
> Alternatively, one could disable the alias commands interactively in
> eshell, without further configuration:
>
> ~ $ fmakunbound (quote eshell/su)
> ~ $ fmakunbound (quote eshell/sudo)
>
> I will document both approches in eshell.texi.
OTOH adding an alias to su/sudo can solve problem:
alias sudo *sudo -p Password: $*
alias su LC_ALL=C *su -l
(if you enter the alias from eshell, you have to escape $)
--
Thierry Volpiatto
Gpg key: http://pgp.mit.edu/
next prev parent reply other threads:[~2010-05-26 5:55 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-20 4:42 bug#6226: Please add a customizable option to NOT call tramp for every sudo command Ken Hori
2010-05-20 6:43 ` Michael Albinus
2010-05-22 3:50 ` Ken Hori
2010-05-22 22:03 ` Michael Albinus
2010-05-23 13:22 ` Stefan Monnier
2010-05-23 17:15 ` Michael Albinus
2010-05-23 18:54 ` Juanma Barranquero
2010-05-24 8:16 ` Ken Hori
2010-05-24 14:05 ` Stefan Monnier
2010-05-26 3:26 ` Michael Albinus
2010-05-26 5:55 ` Thierry Volpiatto [this message]
2010-05-26 10:16 ` Michael Albinus
2010-05-26 13:30 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874ohvjjgb.fsf@tux.homenetwork \
--to=thierry.volpiatto@gmail.com \
--cc=bug-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.