On 02Jul2016 20:13, Xu Wang <xuwang...@gmail.com> wrote:
On Thu, Jun 30, 2016 at 9:10 PM, Will Yardley
<mutt-us...@veggiechinese.net> wrote:
On Thu, Jun 30, 2016 at 08:02:38PM -0400, Xu Wang wrote:
I have read the environment variables section in 'man mutt' and there
does not seem to be a MUTTRC environment variable. One can set using
-F option but sometime environment variable is nice.
Can someone confirm this is correct? Is there a reason for this?
What kind of uses did you have in mind?
You can use environment variables in config files, so you can always
work around this for most of the use cases I can think of by having
source ~/.muttrc-$FOO
in ~/.muttrc, and then define $FOO.
Thank you for responding. That is good tricky to know. You said "for
most of the use cases I can think of". What is the use case you can
think of where the tricky above will not function?
For me it is not ideal because when I execute
source ~/.muttrc-$FOO
then the rest of the .muttrc is still processed. I would like to
process only ~/.muttrc-$FOO.
I hope that has sense.
What about this:
.muttrc
source .muttrc-$FOO
.muttrc-default
all your normal settings
and set $FOO (well, probably something like $MUTT_PROFILE_NAME) to 'default' in
your .profile.
That way your .muttrc runs only the .muttrc-whatever you ask for, and by
default runs your normal settings.
Cheers,
Cameron Simpson <c...@zip.com.au>