Re: send-hooks
> >| send-hook . 'my_hdr From: me@xxxxxxxx'
> >| send-hook ~l 'my_hdr From: lists@xxxxxxxx'
This works fine but the problem is as follows. The two rules above are
in my case more like this:
send-hook . 'my_hdr From: My_Real_Name <gerases@xxxxxxxxxxxxxxxxxxxxx>'
send-hook ~l 'my_hdr From: gerases@xxxxxxxxxxxxxxxxxxxxx'
These send-hook's are in a separate file that is sourced from .muttrc.
Well, in .muttrc I do: set from = "My_Real_Name <gerases@xxxxxxxxxxxxxxxxxxxxx>"
That is, in both cases the address is the same but I want to remove my
real name. Ok, while those two rules do exactly what I want, I have to
mention "gerases@publicschoolworks" 3 times -- once in .muttrc and two
times in the hook rules! What if my address changes? I would have to
remember to change it in three places? It would be nice if I could do:
send-hook . 'my_hdr From: $realname $from'
send-hook ~l 'my_hdr From: $from'
But... It seems that mutt doesn't have variable expansion? I now know
that mutt-ng has it, but in my version of mutt (1.5.9) doing any of the
above results in the variables expanding to nothing. Or am I missing
something?
> | set from=me@xxxxxxxx
> | set realname="John Doe"
> | send-hook . "unmy_hdr From:"
> | send-hook ~l "my_hdr From: lists@xxxxxxxx"
I'm not sure if I understand this correctly, but this assumes that I
keep my "realname" and change email addresses? Actually what I need is the
realname to change. These work fine but realname gets appended every time
(as it should). Also, why "send-hook . 'unmy_hdr From:'"? Won't it
unset the "From:" line every time? How does this work exactly?