Gary Johnson <garyjohn@xxxxxxxxxxxxxxx> [2004:01:10:10:10:56-0800] scribed: > On 2004-01-10, Michael D Schleif <mds@xxxxxxxxxxx> wrote: > > Is there some necessary precedence between folder-hook's and standalone > > color commands? > > > > I use a non-trivial color setup in ~/.muttrc, which works as expected. > > When I do this: > > > > folder-hook cnn "color index blue default '~A'" > > > > color is nowhere as I expect it -- even in folders without `cnn' in > > their label. In other words, this folder-hook destroys all other > > colors, and interferes with other folder-hooks, as well. > > > > What do you think? > > It looks to me like it's doing what you told it to do. When you > enter the cnn folder, the folder-hook is adding > > color index blue default '~A' > > to the end of the list of color commands so that it is executed last > and therefore takes precedence over any earlier color commands. > Since the pattern matches every message, you should see every > message colored blue-on-default. Unless you have another folder- > hook to undo this when you enter other folders, e.g., > > folder-hook . "uncolor index '~A'" > > this coloring will remain in effect forever after entering the cnn > folder. > > If you want to change a low-priority color rule like that one when > you change folders, you'll have to put your other color commands in > folder-hooks, too. I think your hooks will look something like > this: > > folder-hook . "uncolor index '~A'" > folder-hook . "uncolor index <pattern A>" > folder-hook . "uncolor index <pattern B>" > folder-hook cnn "color index blue default '~A'" > folder-hook xyz "color index green default '~A'" > folder-hook . "color index <colors for A> <pattern A>" > folder-hook . "color index <colors for B> <pattern B>" So, are you saying that `folder-hook' always takes precedence over simple `color' commands? If that is the case, then that does answer my question; regardless, how difficult my considerably more complex configuration becomes ;> -- Best Regards, mds mds resource 877.596.8237 - Dare to fix things before they break . . . - Our capacity for understanding is inversely proportional to how much we think we know. The more I know, the more I know I don't know . . . --
Attachment:
pgpFVZzRXFYya.pgp
Description: PGP signature