'\" t .\" Man page generated from reStructuredText. . . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .TH "NOTMUCH-SHOW" "1" "Oct 03, 2024" "0.38.3" "notmuch" .SH NAME notmuch-show \- show messages matching the given search terms .SH SYNOPSIS .sp \fBnotmuch\fP \fBshow\fP [\fIoption\fP ...] <\fIsearch\-term\fP> ... .SH DESCRIPTION .sp Shows all messages matching the search terms. .sp See \fI\%notmuch\-search\-terms\fP for details of the supported syntax for . .sp The messages will be grouped and sorted based on the threading (all replies to a particular message will appear immediately after that message in date order). The output is not indented by default, but depth tags are printed so that proper indentation can be performed by a post\-processor (such as the emacs interface to notmuch). .sp Supported options for \fBshow\fP include .INDENT 0.0 .TP .B \-\-duplicate=N Output duplicate number N. The numbering starts from 1, and matches the order used by \fI\%search \-\-duplicate\fP and \fI\%search \-\-output=files\fP .UNINDENT .INDENT 0.0 .TP .B \-\-entire\-thread=(true|false) If true, \fBnotmuch show\fP outputs all messages in the thread of any message matching the search terms; if false, it outputs only the matching messages. For \fB\-\-format=json\fP and \fB\-\-format=sexp\fP this defaults to true. For other formats, this defaults to false. .UNINDENT .INDENT 0.0 .TP .B \-\-format=(text|json|sexp|mbox|raw) .INDENT 7.0 .TP .B text (default for messages) The default plain\-text format has all text\-content MIME parts decoded. Various components in the output, (\fBmessage\fP, \fBheader\fP, \fBbody\fP, \fBattachment\fP, and MIME \fBpart\fP), will be delimited by easily\-parsed markers. Each marker consists of a Control\-L character (ASCII decimal 12), the name of the marker, and then either an opening or closing brace, (\(aq{\(aq or \(aq}\(aq), to either open or close the component. For a multipart MIME message, these parts will be nested. .TP .B json The output is formatted with Javascript Object Notation (JSON). This format is more robust than the text format for automated processing. The nested structure of multipart MIME messages is reflected in nested JSON output. By default JSON output includes all messages in a matching thread; that is, by default, \fB\-\-format=json\fP sets \fB\-\-entire\-thread\fP\&. The caller can disable this behaviour by setting \fB\-\-entire\-thread=false\fP\&. The JSON output is always encoded as UTF\-8 and any message content included in the output will be charset\-converted to UTF\-8. .TP .B sexp The output is formatted as the Lisp s\-expression (sexp) equivalent of the JSON format above. Objects are formatted as property lists whose keys are keywords (symbols preceded by a colon). True is formatted as \fBt\fP and both false and null are formatted as \fBnil\fP\&. As for JSON, the s\-expression output is always encoded as UTF\-8. .TP .B mbox All matching messages are output in the traditional, Unix mbox format with each message being prefixed by a line beginning with \(dqFrom \(dq and a blank line separating each message. Lines in the message content beginning with \(dqFrom \(dq (preceded by zero or more \(aq>\(aq characters) have an additional \(aq>\(aq character added. This reversible escaping is termed \(dqmboxrd\(dq format and described in detail here: .INDENT 7.0 .INDENT 3.5 \X'tty: link http://homepage.ntlworld.com/jonathan.deboynepollard/FGA/mail-mbox-formats.html'\fI\%http://homepage.ntlworld.com/jonathan.deboynepollard/FGA/mail\-mbox\-formats.html\fP\X'tty: link' .UNINDENT .UNINDENT .TP .B raw (default if \fB\-\-part\fP is given) Write the raw bytes of the given MIME part of a message to standard out. For this format, it is an error to specify a query that matches more than one message. .sp If the specified part is a leaf part, this outputs the body of the part after performing content transfer decoding (but no charset conversion). This is suitable for saving attachments, for example. .sp For a multipart or message part, the output includes the part headers as well as the body (including all child parts). No decoding is performed because multipart and message parts cannot have non\-trivial content transfer encoding. Consumers of this may need to implement MIME decoding and similar functions. .UNINDENT .UNINDENT .INDENT 0.0 .TP .B \-\-format\-version=N Use the specified structured output format version. This is intended for programs that invoke \fI\%notmuch\fP internally. If omitted, the latest supported version will be used. .UNINDENT .INDENT 0.0 .TP .B \-\-part=N Output the single decoded MIME part N of a single message. The search terms must match only a single message. Message parts are numbered in a depth\-first walk of the message MIME structure, and are identified in the \(aqjson\(aq, \(aqsexp\(aq or \(aqtext\(aq output formats. .sp Note that even a message with no MIME structure or a single body part still has two MIME parts: part 0 is the whole message (headers and body) and part 1 is just the body. .UNINDENT .INDENT 0.0 .TP .B \-\-sort=(newest\-first|oldest\-first) This option can be used to present results in either chronological order (\fBoldest\-first\fP) or reverse chronological order (\fBnewest\-first\fP). .sp Only threads as a whole are reordered. Ordering of messages within each thread will not be affected by this flag, since that order is always determined by the thread\(aqs replies. .sp By default, results will be displayed in reverse chronological order, (that is, the newest results will be displayed first). .UNINDENT .INDENT 0.0 .TP .B \-\-offset=[\-]N Skip displaying the first N results. With the leading \(aq\-\(aq, start at the Nth result from the end. .UNINDENT .INDENT 0.0 .TP .B \-\-limit=N Limit the number of displayed results to N. .UNINDENT .INDENT 0.0 .TP .B \-\-verify Compute and report the validity of any MIME cryptographic signatures found in the selected content (e.g., \(dqmultipart/signed\(dq parts). Status of the signature will be reported (currently only supported with \fB\-\-format=json\fP and \fB\-\-format=sexp\fP), and the multipart/signed part will be replaced by the signed data. .UNINDENT .INDENT 0.0 .TP .B \-\-decrypt=(false|auto|true|stash) If \fBtrue\fP, decrypt any MIME encrypted parts found in the selected content (e.g., \(dqmultipart/encrypted\(dq parts). Status of the decryption will be reported (currently only supported with \fB\-\-format=json\fP and \fB\-\-format=sexp\fP) and on successful decryption the multipart/encrypted part will be replaced by the decrypted content. .sp \fBstash\fP behaves like \fBtrue\fP, but upon successful decryption it will also stash the message\(aqs session key in the database, and index the cleartext of the message, enabling automatic decryption in the future. .sp If \fBauto\fP, and a session key is already known for the message, then it will be decrypted, but notmuch will not try to access the user\(aqs keys. .sp Use \fBfalse\fP to avoid even automatic decryption. .sp Non\-automatic decryption (\fBstash\fP or \fBtrue\fP, in the absence of a stashed session key) expects a functioning \fB\X'tty: link https://manpages.debian.org/gpg-agent.1.html'\fI\%gpg\-agent(1)\fP\X'tty: link'\fP to provide any needed credentials. Without one, the decryption will fail. .sp Note: setting either \fBtrue\fP or \fBstash\fP here implies \fB\-\-verify\fP\&. .sp Here is a table that summarizes each of these policies: .TS box center; l|l|l|l|l. T{ T} T{ false T} T{ auto T} T{ true T} T{ stash T} _ T{ Show cleartext if session key is already known T} T{ T} T{ X T} T{ X T} T{ X T} _ T{ Use secret keys to show cleartext T} T{ T} T{ T} T{ X T} T{ X T} _ T{ Stash any newly recovered session keys, reindexing message if found T} T{ T} T{ T} T{ T} T{ X T} .TE .sp Note: \fB\-\-decrypt=stash\fP requires write access to the database. Otherwise, \fBnotmuch show\fP operates entirely in read\-only mode. .sp Default: \fBauto\fP .UNINDENT .INDENT 0.0 .TP .B \-\-exclude=(true|false) Specify whether to omit threads only matching search.exclude_tags from the search results (the default) or not. In either case the excluded message will be marked with the exclude flag (except when output=mbox when there is nowhere to put the flag). .sp If \fB\-\-entire\-thread\fP is specified then complete threads are returned regardless (with the excluded flag being set when appropriate) but threads that only match in an excluded message are not returned when \fB\-\-exclude=true.\fP .sp The default is \fB\-\-exclude=true.\fP .UNINDENT .INDENT 0.0 .TP .B \-\-body=(true|false) If true (the default) \fBnotmuch show\fP includes the bodies of the messages in the output; if false, bodies are omitted. \fB\-\-body=false\fP is only implemented for the text, json and sexp formats and it is incompatible with \fB\-\-part > 0.\fP .sp This is useful if the caller only needs the headers as body\-less output is much faster and substantially smaller. .UNINDENT .INDENT 0.0 .TP .B \-\-include\-html Include \(dqtext/html\(dq parts as part of the output (currently only supported with \fB\-\-format=text\fP, \fB\-\-format=json\fP and \fB\-\-format=sexp\fP). By default, unless \fB\-\-part=N\fP is used to select a specific part or \fB\-\-include\-html\fP is used to include all \(dqtext/html\(dq parts, no part with content type \(dqtext/html\(dq is included in the output. .UNINDENT .sp A common use of \fBnotmuch show\fP is to display a single thread of email messages. For this, use a search term of \(dqthread:\(dq as can be seen in the first column of output from the \fI\%notmuch\-search\fP command. .SH CONFIGURATION .sp Structured output (json / sexp) is influenced by the configuration option \fI\%show.extra_headers\fP\&. See \fI\%notmuch\-config\fP for details. .SH EXIT STATUS .sp This command supports the following special exit status codes .INDENT 0.0 .TP .B \fB20\fP The requested format version is too old. .TP .B \fB21\fP The requested format version is too new. .UNINDENT .SH SEE ALSO .sp \fI\%notmuch\fP, \fI\%notmuch\-config\fP, \fI\%notmuch\-count\fP, \fI\%notmuch\-dump\fP, \fI\%notmuch\-hooks\fP, \fI\%notmuch\-insert\fP, \fI\%notmuch\-new\fP, \fI\%notmuch\-reply\fP, \fI\%notmuch\-restore\fP, \fI\%notmuch\-search\fP, \fI\%notmuch\-search\-terms\fP, \fI\%notmuch\-tag\fP .SH AUTHOR Carl Worth and many others .SH COPYRIGHT 2009-2024, Carl Worth and many others .\" Generated by docutils manpage writer. .