Fairlight <[EMAIL PROTECTED]> wrote:
>
> Now if someone could just help me out with UNsetting hooks from a few
> days ago...still haven't found an answer...  :)

That's because there isn't one.  There is no way to remove a hook.

However, I haven't really seen a case where a hook needed to be removed.
Usually what you do is to specify a very general hook first in your
list.  This hook will set default behavior that you desire.  Then, later
hooks can specify more specific behavior for specific cases.  Since the
default hook will apply first, specific hooks will override it when
necessary.  When those conditions no longer apply, the default hook will
once again be the one that applies.

Does this make sense?  Here's an example from my send-hooks:

    send-hook ~A                        set signature=~/.localsig
    send-hook '! ~C "\.hp\.com$"'       set signature=~/.remotesig  

For most messages, only the first hook applies (since it applies to all
messages!), but if I send a message to someone in the hp.com domain, the
second hook will also apply.  Since it comes later in the list, it
overrides the first hook, but only in that special case.  If I send a
message to someone not in that domain, the first hook resets the
variable to the default.

Note that this ties in with what I was saying before about how auto_edit
and edit_headers can prevent hooks from working the way you want.  Hooks
apply only when you initially compose a message.  But if you use
auto_edit, Mutt doesn't know what hooks to apply, because you haven't
specified an address yet!  So the signature setting would always be the
default, if I used auto_edit.

-- 
David DeSimone   | "The doctrine of human equality reposes on this:
[EMAIL PROTECTED]   |  that there is no man really clever who has not
Hewlett-Packard  |  found that he is stupid." -- Gilbert K. Chesterson
UX WTEC Engineer |    PGP: 5B 47 34 9F 3B 9A B0 0D  AB A6 15 F1 BB BE 8C 44

Reply via email to