]> git.cworth.org Git - notmuch-wiki/blob - manpages/notmuch-hooks-5.mdwn
manpages/ for quality control. manpages.mdwn todo
[notmuch-wiki] / manpages / notmuch-hooks-5.mdwn
1 <h1>NOTMUCH-HOOKS(5)</h1>
2
3 <h2>NAME</h2>
4
5 <pre>
6        notmuch-hooks - hooks for notmuch
7 </pre>
8
9 <h2>SYNOPSIS</h2>
10
11 <pre>
12         $DATABASEDIR/.notmuch/hooks/*
13 </pre>
14
15 <h2>DESCRIPTION</h2>
16
17 <pre>
18        Hooks  are  scripts (or arbitrary executables or symlinks to such) that
19        notmuch invokes before and after certain actions. These scripts  reside
20        in  the .notmuch/hooks directory within the database directory and must
21        have executable permissions.
22 </pre>
23
24 <pre>
25        The currently available hooks are described below.
26 </pre>
27
28 <pre>
29            <b>pre-new</b>
30                This hook is invoked by the  <b>new</b>  command  before  scanning  or
31                importing  new  messages  into the database. If this hook exits
32                with a non-zero status, notmuch will abort  further  processing
33                of the <b>new</b> command.
34 </pre>
35
36 <pre>
37                Typically this hook is used for fetching or delivering new mail
38                to be imported into the database.
39 </pre>
40
41 <pre>
42            <b>post-new</b>
43                This hook is invoked by the <b>new</b> command after new messages have
44                been  imported  into  the  database  and initial tags have been
45                applied. The hook will not be run if there have been any errors
46                during the scan or import.
47 </pre>
48
49 <pre>
50                Typically  this  hook is used to perform additional query-based
51                tagging on the imported messages.
52 </pre>
53
54 <h2>SEE ALSO</h2>
55
56 <pre>
57        <b>notmuch</b>(1), <b>notmuch-config</b>(1), <b>notmuch-count</b>(1), <b>notmuch-dump</b>(1),  <b>not-</b>
58        <b>much-new</b>(1),  <b>notmuch-reply</b>(1),  <b>notmuch-restore</b>(1), <b>notmuch-search</b>(1),
59        <b>notmuch-search-terms</b>(7), <b>notmuch-show</b>(1), <b>notmuch-tag</b>(1)
60 </pre>
61
62 <h1>Notmuch 0.13.2</h1>