> Yes the macros work and thankyou for that.
>
> However, the problem I am experiencing with the macro is that:
>
> IF the <tag-pattern> doesn't match any messages
> THEN
> The following "<tag-prefix><save-message>+mailbox<enter" command saves
> the currently selected message into "mailbox" file, even though it
> doesn't match anything.
> ENDIF
I realize that the above is an outstanding issue with my macro(s), for
which I have to find an acceptable solution. The way I get around this
problem is to NOT execute a macro that you don't need. So then "how do I
know *which* macro to execute?" -- you probably will ask. The answer is
-- color coding the "index" when the $spoolfile is first read. Soooo... I
have all mutt-users msgs = brightred; cygwin=brightblue; personal=green;
etc etc. I then execute the macro required as per the "color chart" ;)
Works for me!
> I have tried using "save-hook" to specify the pattern for the default "."
> pattern, so that I can remove the "+mailbox" from the
> "<save-message>+mailbox<enter" command (leaving "<save-message><enter>"),
> with the idea that if there weren't any tagged messages at that time, then
> at least the currently selected message would go in an appropriate place
> (via the "save-hook"), but that doesn't appear to work - you have to
> specify the mail-box or else the <save-message> command doesn't work.
Granted mine is a somewhat uninformed opinion, but....IMO, using
"save-hook" with these macros is inviting trouble. AFAIK, the way I wrote
the macros (i.e., explicitly loading the macro with a mailbox) overrides
the save-hooks - so the msgs go where I want them to. Correct me if I'm
wrong here you silent "Mutt Macro Maestros" (MMM) ! The only save-hooks I
use is what I've set up as "default" -- used when I save a specific
message after reading it.
> I want to abort or skip over the "<save-message>...<enter>" bit of the
> macro if the <tag-prefix> command returns an error or if you can detect
> that the <tag-pattern> command didn't select any messages.
I hear you -- but I haven't solved the " no files tagged, so do nothing"
issue. Like I said above -- DON'T use the macros that you don't need for
the time being, until we come up with a "slicker than snot on a
door-knob" solution. ;,) Again -- color-code the "groups" of messages in
your /etc/muttrc file, then use the appropriate macro. Later...
--
-duke
Calgary, Alberta, Canada