1 .TH NOTMUCH-DUMP 1 2013-12-30 "Notmuch 0.17"
3 notmuch-dump \- creates a plain-text dump of the tags of each message
8 .RB [ "\-\-format=(sup|batch-tag)" "] [--]"
9 .RI "[ --output=<" filename "> ] [--]"
10 .RI "[ <" search-term ">...]"
14 Dump tags for messages matching the given search terms.
16 Output is to the given filename, if any, or to stdout.
18 These tags are the only data in the notmuch database that can't be
19 recreated from the messages themselves. The output of notmuch dump is
20 therefore the only critical thing to backup (and much more friendly to
21 incremental backup than the native database files.)
24 .B \-\-format=(sup|batch-tag)
26 Notmuch restore supports two plain text dump formats, both with one message-id
27 per line, followed by a list of tags.
35 dump format is intended to more robust against malformed message-ids
36 and tags containing whitespace or non-\fBascii\fR(7) characters.
37 Each line has the form
40 .RI "+<" "encoded-tag" "> " "" "+<" "encoded-tag" "> ... -- " "" " id:<" quoted-message-id >
42 Tags are hex-encoded by replacing every byte not matching the regex
46 where nn is the two digit hex encoding. The message ID is a valid Xapian
47 query, quoted using Xapian boolean term quoting rules: if the ID contains
48 whitespace or a close paren or starts with a double quote, it must be
49 enclosed in double quotes and double quotes inside the ID must be doubled.
50 The astute reader will notice this is a special case of the batch input
51 format for \fBnotmuch-tag\fR(1); note that the single message-id query is
52 mandatory for \fBnotmuch-restore\fR(1).
63 dump file format is specifically chosen to be
64 compatible with the format of files produced by sup-dump.
65 So if you've previously been using sup for mail, then the
67 command provides you a way to import all of your tags (or labels as
69 Each line has the following form
77 with zero or more tags are separated by spaces. Note that (malformed)
78 message-ids may contain arbitrary non-null characters. Note also
79 that tags with spaces will not be correctly restored with this format.
86 With no search terms, a dump of all messages in the database will be
87 generated. A "--" argument instructs notmuch that the
88 remaining arguments are search terms.
90 See \fBnotmuch-search-terms\fR(7)
91 for details of the supported syntax for <search-terms>.
96 \fBnotmuch\fR(1), \fBnotmuch-config\fR(1), \fBnotmuch-count\fR(1),
97 \fBnotmuch-hooks\fR(5), \fBnotmuch-insert\fR(1), \fBnotmuch-new\fR(1),
98 \fBnotmuch-reply\fR(1), \fBnotmuch-restore\fR(1), \fBnotmuch-search\fR(1),
99 \fBnotmuch-search-terms\fR(7), \fBnotmuch-show\fR(1),