/sudo::/etc/hosts with tramp prompts for a password even though I have passwordless sudo. I use ido.
$ sudo grep NOPASSWD /etc/sudoers %wheel ALL=(ALL) NOPASSWD: ALL
Is there any way to fix this?
Emacs Stack Exchange is a question and answer site for those using, extending or developing Emacs. It only takes a minute to sign up.Sign up to join this community
The issue seemed to have something to do with ido, so I added Option B from here and it works great.
(defadvice ido-find-file (after find-file-sudo activate) "Find file as root if necessary." (unless (and buffer-file-name (file-writable-p buffer-file-name)) (find-alternate-file (concat "/sudo:root@localhost:" buffer-file-name))))