10 **notmuch** **reply** [option ...] <*search-term*> ...
15 Constructs a reply template for a set of messages.
17 To make replying to email easier, **notmuch reply** takes an existing
18 set of messages and constructs a suitable mail template. Its To:
19 address is set according to the original email in this way: if the
20 Reply-to: header is present and different from any To:/Cc: address it
21 is used, otherwise From: header is used. Unless
22 ``--reply-to=sender`` is specified, values from the To: and Cc: headers
23 are copied, but not including any of the current user's email addresses
24 (as configured in primary\_mail or other\_email in the .notmuch-config
25 file) in the recipient list.
27 It also builds a suitable new subject, including Re: at the front (if
28 not already present), and adding the message IDs of the messages being
29 replied to to the References list and setting the In-Reply-To: field
32 Finally, the original contents of the emails are quoted by prefixing
33 each line with '> ' and included in the body.
35 The resulting message template is output to stdout.
37 Supported options for **reply** include
41 .. option:: --format=(default|json|sexp|headers-only)
44 Includes subject and quoted message body as an RFC 2822
48 Produces JSON output containing headers for a reply message
49 and the contents of the original message. This output can be
50 used by a client to create a reply message intelligently.
53 Produces S-Expression output containing headers for a reply
54 message and the contents of the original message. This output
55 can be used by a client to create a reply message
59 Only produces In-Reply-To, References, To, Cc, and Bcc
62 .. option:: --format-version=N
64 Use the specified structured output format version. This is
65 intended for programs that invoke :any:`notmuch(1)` internally. If
66 omitted, the latest supported version will be used.
68 .. option:: --reply-to=(all|sender)
71 Replies to all addresses.
74 Replies only to the sender. If replying to user's own message
75 (Reply-to: or From: header is one of the user's configured
76 email addresses), try To:, Cc:, and Bcc: headers in this
77 order, and copy values from the first that contains something
78 other than only the user's addresses.
80 .. option:: --decrypt=(false|auto|true)
82 If ``true``, decrypt any MIME encrypted parts found in the
83 selected content (i.e., "multipart/encrypted" parts). Status
84 of the decryption will be reported (currently only supported
85 with ``--format=json`` and ``--format=sexp``), and on successful
86 decryption the multipart/encrypted part will be replaced by
87 the decrypted content.
89 If ``auto``, and a session key is already known for the
90 message, then it will be decrypted, but notmuch will not try
91 to access the user's secret keys.
93 Use ``false`` to avoid even automatic decryption.
95 Non-automatic decryption expects a functioning
96 :manpage:`gpg-agent(1)` to provide any needed credentials. Without
97 one, the decryption will likely fail.
101 See :any:`notmuch-search-terms(7)` for details of the supported syntax for
104 Note: It is most common to use **notmuch reply** with a search string
105 matching a single message, (such as id:<message-id>), but it can be
106 useful to reply to several messages at once. For example, when a series
107 of patches are sent in a single thread, replying to the entire thread
108 allows for the reply to comment on issues found in multiple patches. The
109 default format supports replying to multiple messages at once, but the
110 JSON and S-Expression formats do not.
115 This command supports the following special exit status codes
118 The requested format version is too old.
121 The requested format version is too new.
127 :any:`notmuch-config(1)`,
128 :any:`notmuch-count(1)`,
129 :any:`notmuch-dump(1)`,
130 :any:`notmuch-hooks(5)`,
131 :any:`notmuch-insert(1)`,
132 :any:`notmuch-new(1)`,
133 :any:`notmuch-restore(1)`,
134 :any:`notmuch-search(1)`,
135 :any:`notmuch-search-terms(7)`,
136 :any:`notmuch-show(1)`,
137 :any:`notmuch-tag(1)`