From: Mick <michaelkintzios@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] heads-up: 2011-05-01 baselayout news
Date: Thu, 5 May 2011 20:57:47 +0100 [thread overview]
Message-ID: <201105052057.58191.michaelkintzios@gmail.com> (raw)
In-Reply-To: <201105051025.19075.wonko@wonkology.org>
[-- Attachment #1: Type: Text/Plain, Size: 2816 bytes --]
On Thursday 05 May 2011 09:25:18 Alex Schuster wrote:
> Mick wrote:
> > On Monday 02 May 2011 12:52:12 Alex Schuster wrote:
> > > Mick writes:
> > > > Thanks. Not sure if there is a difference between an env.d variable
> > > > and a profile.d variable.
> > >
> > > None you will notice, both /etc/profile.env and scripts in
> > > /etc/profile.d/ are sourced in /etc/profile. profile.env contains all
> > > stuff in /etc/env.d/ after you ran env-update.
> >
> > Hmm ... I initially set up a file in /etc/profile.d/99editor with
> >
> > EDITOR="/usr/bin/vim"
> >
> > in it. Upon reboot I still got:
> >
> > echo $EDITOR
> > /bin/nano
>
> I looked into /etc/profile, and right at the bottom it does this:
>
> for sh in /etc/profile.d/*.sh ; do
> [ -r "$sh" ] && . "$sh"
> done
> unset sh
>
> So the file needs to have the .sh suffix.
I see! It makes sense now.
> > So, I thought of moving it into /etc/env.d/97editor. Upon another reboot
> > (troubleshooting network problems) I again found out that nano is my
> > default editor ... neither locations seem to being read at boot time?
> >
> > Running env-update && source /etc/profile did not make any difference.
> >
> > Is the number prefix important? Does it have to be 99editor? If so, how
> > does one discover the correct number for each variable?
>
> Maybe the 99 is what eselect wants the number to be. If you manage files in
> there yourself, I think it should not matter. The result of env-update in
> /etc/profile.env is sorted alphabetically, so the order of file in
> /etc/env.d should not matter, I think.
>
> > > I do not manually change things in env.d, but with 'eselect editor set
> > > <n>' you can create a file /etc/env.d/99editor which will set the
> > > EDITOR variable to the editor you gave eselect as argument. Enter
> > > eselect editor list to se what's available, or just give the editor
> > > path as argument to eselect.
> >
> > # eselect editor list
> >
> > Available targets for the EDITOR variable:
> > [1] /bin/nano
> > [2] /usr/bin/ex
> > [3] /usr/bin/vi
> > [ ] (free form)
> >
> > What does the "[ ] (free form)" above refer to?
>
> That you can specify any other binary as editor if you like, with "eselect
> editor set /path/to/my/editor".
>
> > > > I've added mine to /etc/profile.d for now. I'll
> > > > see what gives when I reboot.
> > >
> > > A relogin would be enough. Or '. /etc/profile' in the shell, this is
> > > what eselects suggests to do. Or bash -l, or xterm -ls.
Yes, but I was also testing some other issues with my network setup and also
startup scripts.
> > Yep, setting the EDITOR using eselect works fine.
>
> Hooray!
:) Thanks for your advice!
--
Regards,
Mick
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
next prev parent reply other threads:[~2011-05-05 20:01 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-02 9:03 [gentoo-user] heads-up: 2011-05-01 baselayout news Thanasis
2011-05-02 9:11 ` Thanasis
2011-05-02 9:31 ` Mick
2011-05-02 17:11 ` Mark Knecht
2011-05-02 17:36 ` Mick
2011-05-02 17:55 ` Mark Knecht
2011-05-03 2:23 ` William Hubbs
2011-05-02 18:02 ` Neil Bothwick
2011-05-02 18:16 ` Mark Knecht
2011-05-02 18:48 ` Neil Bothwick
2011-05-02 18:54 ` Mark Knecht
2011-05-02 22:07 ` Mark Knecht
2011-05-03 5:07 ` Mick
2011-05-02 19:00 ` Felix Leif Keppmann
2011-05-02 10:18 ` Dale
2011-05-02 9:43 ` Mick
2011-05-02 10:05 ` Mick
2011-05-02 10:26 ` Thanasis
2011-05-02 10:50 ` Mick
2011-05-02 11:25 ` Thanasis
2011-05-02 11:52 ` Alex Schuster
2011-05-02 12:35 ` Mick
2011-05-05 8:25 ` Alex Schuster
2011-05-05 9:06 ` Alan McKinnon
2011-05-05 19:57 ` Mick [this message]
2011-05-02 10:06 ` Thanasis
2011-05-03 0:16 ` [gentoo-user] " walt
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=201105052057.58191.michaelkintzios@gmail.com \
--to=michaelkintzios@gmail.com \
--cc=gentoo-user@lists.gentoo.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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox