]> granicus.if.org Git - neomutt/commitdiff
Doc fixes and updates concerning hooks
authorAlain Bench <veronatif@free.fr>
Sun, 4 Mar 2007 18:26:29 +0000 (19:26 +0100)
committerAlain Bench <veronatif@free.fr>
Sun, 4 Mar 2007 18:26:29 +0000 (19:26 +0100)
- Add reply-hooks and send2-hooks in lists they miss.
- Fix that they all take full patterns, not only regexps.
- Note interaction with $default_hook.
- Enumerate them in execution order/increasing priority.
- Add iconv-hook, remove a duplicate charset-hook.

doc/manual.xml.head
init.h

index cba32e48361cc62eb705ea736069522191a3c2f2..8e9624c601a71ef37a34d70fb7e1211b17fa6cd6 100644 (file)
@@ -4026,8 +4026,9 @@ send-hook ~C'^b@b\.b$' my_hdr from: c@c.c
 <title>Message Matching in Hooks</title>
 
 <para>
-Hooks that act upon messages (<literal>send-hook, save-hook, fcc-hook,
-message-hook</literal>) are evaluated in a slightly different manner.  For the other
+Hooks that act upon messages (<literal>message-hook, reply-hook,
+send-hook, send2-hook, save-hook, fcc-hook</literal>) are evaluated in a
+slightly different manner. For the other
 types of hooks, a <link linkend="regexp">regular expression</link> is
 sufficient.  But in dealing with messages a finer grain of control is
 needed for matching since for different purposes you want to match
@@ -5987,6 +5988,12 @@ The following are the commands understood by mutt.
 </listitem>
 <listitem>
 
+<para>
+<literal><link linkend="charset-hook">iconv-hook</link></literal> <emphasis>charset</emphasis> <emphasis>local-charset</emphasis>
+</para>
+</listitem>
+<listitem>
+
 <para>
 <literal><link linkend="color">color</link></literal> <emphasis>object</emphasis> <emphasis>foreground</emphasis> <emphasis>background</emphasis> &lsqb; <emphasis>regexp</emphasis> &rsqb;
 </para>
@@ -6035,12 +6042,6 @@ The following are the commands understood by mutt.
 </listitem>
 <listitem>
 
-<para>
-<literal><link linkend="charset-hook">charset-hook</link></literal> <emphasis>charset</emphasis> <emphasis>local-charset</emphasis>
-</para>
-</listitem>
-<listitem>
-
 <para>
 <literal><link linkend="ignore">ignore</link></literal> <emphasis>pattern</emphasis> &lsqb; <emphasis>pattern</emphasis> ... &rsqb;
 </para>
@@ -6162,13 +6163,19 @@ The following are the commands understood by mutt.
 <listitem>
 
 <para>
-<literal><link linkend="send-hook">send-hook</link></literal> <emphasis>regexp</emphasis> <emphasis>command</emphasis>
+<literal><link linkend="send-hook">reply-hook</link></literal> <emphasis>pattern</emphasis> <emphasis>command</emphasis>
+</para>
+</listitem>
+<listitem>
+
+<para>
+<literal><link linkend="send-hook">send-hook</link></literal> <emphasis>pattern</emphasis> <emphasis>command</emphasis>
 </para>
 </listitem>
 <listitem>
 
 <para>
-<literal><link linkend="send-hook">reply-hook</link></literal> <emphasis>regexp</emphasis> <emphasis>command</emphasis>
+<literal><link linkend="send-hook">send2-hook</link></literal> <emphasis>pattern</emphasis> <emphasis>command</emphasis>
 </para>
 </listitem>
 <listitem>
diff --git a/init.h b/init.h
index b940b32ab79a4ad08080579073fc985491ce8c09..ce5ff7818dee8bc2686416db59fe95255d34449e 100644 (file)
--- a/init.h
+++ b/init.h
@@ -486,8 +486,8 @@ struct option_t MuttVars[] = {
   { "default_hook",    DT_STR,  R_NONE, UL &DefaultHook, UL "~f %s !~P | (~P ~C %s)" },
   /*
   ** .pp
-  ** This variable controls how send-hooks, message-hooks, save-hooks,
-  ** and fcc-hooks will
+  ** This variable controls how message-hooks, reply-hooks, send-hooks,
+  ** send2-hooks, save-hooks, and fcc-hooks will
   ** be interpreted if they are specified with only a simple regexp,
   ** instead of a matching pattern.  The hooks are expanded when they are
   ** declared, so a hook will be interpreted according to the value of this