Gentoo Archives: gentoo-user

From: Mike Edenfield <kutulu@××××××.org>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Am I wrong?..
Date: Thu, 01 Oct 2009 14:50:27
Message-Id: 4AC4C1B0.70307@kutulu.org
In Reply to: [gentoo-user] Am I wrong?.. by "Arthur D."
1 On 10/1/2009 10:44 AM, Arthur D. wrote:
2
3 > I just installed VIM with emerge, and removed nano because I considered
4 > it to be absolutely unnecessary in my system. Why I need nano? I am a VIM
5 > fan. And here the troubles begin...
6 > Run "sudo visudo" and you get this:
7 > ~ $ sudo visudo
8 > visudo: no editor found (editor path = /bin/nano)
9 > ~ $ env | grep -i edit
10 > EDITOR=/usr/bin/vim
11
12
13 You have two options:
14
15 1. Tell sudo to preserve the EDITOR variable in /etc/sudoers:
16
17 Defaults env_keep += "EDITOR VISUAL PAGER"
18
19 Otherwise sudo will ignore your environment and use the defaults for the
20 new user.
21
22 2. Change the default editor on your system by putting something in
23 /etc/env.d:
24
25 apollo ~ # cat /etc/env.d/99editor
26 EDITOR="vim"
27
28
29 --Mike

Replies

Subject Author
Re: [gentoo-user] Am I wrong?.. "Arthur D." <spinal.by@××××.ru>