Hei hei, On Sun, Mar 10, 2013 at 07:59:01AM -0400, Patrick Shanahan wrote: > > > send-hook . set from=your@emailaddy > > > > I have this line in my send hooks: > > > > send-hook "~C ^netz39.*@lists\\.netz39\\.de$" "my_hdr From: Alexander Dahl > > <[email protected]>" > > > > Where do I put the one above, before or after? What does it actually > > do and why does it not affect my send hook itself? > > You set the default "send-hook . ..." first as "send-hook" is set on the > *last* match when parsing the config file. Since you only had one > send-hook, after it first matched, it remained "matched" until you reset > it by restarting mutt. The "send-hook . ..." matches everything so the > second send-hook will not be matched unless it is triggered by the > conditions specified, and *only* for the instances where it matches. The > default, "send-hook . ...", will be triggered on the next pass thru the > config file.
This would work for those mailing lists, but there's another problem.
After defining my send-hooks in a file I include like this:
source ~/.mutt/send-hooks
I set some more options:
set reverse_name
set realname = 'Alexander Dahl'
set from = "[email protected]"
set use_from = yes
alternates "[email protected]|[email protected]|[email protected]"
Now my previously defined send hook
send-hook . "my_hdr From: Alexander Dahl <[email protected]>"
results in [email protected] being my from address every time where I
could just reply and mutt chose my mail address I got the mail to as
new from address for my reply. Is it possible to restore this
behaviour without dropping the "default" send-hook and without having
to write a send-hook for each and every mailing list?
Or: can mutt somehow detect my mail address where I get the mail to on
mailing lists and set it as from address when using (list) reply as it
works without mailing lists where my address is directly in To or Cc?
This is why I wrote the first send-hook, it's exactly one mailing list
where I use another address but mutt didn't recognize this.
Bonus question while we're at it: I wrote my mutt config some years
ago, why would I have wanted to use 'my_hdr From:
[email protected]' instead of 'set [email protected]'?
Greets
Alex
--
»With the first link, the chain is forged. The first speech censured,
the first thought forbidden, the first freedom denied, chains us all
irrevocably.« (Jean-Luc Picard, quoting Judge Aaron Satie)
*** GnuPG-FP: 02C8 A590 7FE5 CA5F 3601 D1D5 8FBA 7744 CC87 10D0 ***
pgpJIlYCzPDQB.pgp
Description: PGP signature
