[Top][All Lists]

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

Re: editing /etc/sudoers

From: Jeff Bauer
Subject: Re: editing /etc/sudoers
Date: Sun, 16 Jun 2019 09:18:29 -0500
User-agent: Mutt/1.11.4 (2019-03-13)

On Sat, Jun 15, 2019 at 07:27:57PM -0700, Quiliro's lists wrote:
> Regarding the EDITOR variable, if Guix is the installer of the needed
> editor it is the only situation when this regards to Guix.
> Would you please clarify your issue?

Issue clarified up-thread:

Generally, assigning the environment variable EDITOR works
for visudo(*), but it appears /usr/bin/vi is hard-coded in
guix's visudo as it does not acknowledge EDITOR.

$ EDITOR=vim visudo ~/etc/guix/sudoers
visudo: no editor found (editor path = /usr/bin/vi)

David Larsson suggested using SUDO_EDITOR, however that
doesn't work either:

$ SUDO_EDITOR=vim visudo ~/etc/guix/sudoers
visudo: no editor found (editor path = /usr/bin/vi)

I'll still use visudo to check my local sudoers file on
the command line, though it's more challenging to remember
to check it (and the consequences of borking sudoers are

$ visudo --check -f ~/etc/guix/sudoers
~/etc/guix/sudoers: parsed OK

I'm guessing /usr/bin/vi has been hard coded into visudo
for security reasons, but it doesn't make sense if the
/usr/bin/vi editor doesn't exist on Guix System.


(*) Or at least it has on other system distros where nano
was the default editor.

reply via email to

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