1 Return-Path: <bremner@tethera.net>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by olra.theworths.org (Postfix) with ESMTP id 3CDB6431FC2
\r
6 for <notmuch@notmuchmail.org>; Tue, 28 Jan 2014 08:13:11 -0800 (PST)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]
\r
13 Received: from olra.theworths.org ([127.0.0.1])
\r
14 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
15 with ESMTP id E3+TXQpA2J9q for <notmuch@notmuchmail.org>;
\r
16 Tue, 28 Jan 2014 08:13:06 -0800 (PST)
\r
17 Received: from yantan.tethera.net (yantan.tethera.net [199.188.72.155])
\r
18 (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))
\r
19 (No client certificate requested)
\r
20 by olra.theworths.org (Postfix) with ESMTPS id 3E400431FBF
\r
21 for <notmuch@notmuchmail.org>; Tue, 28 Jan 2014 08:13:06 -0800 (PST)
\r
22 Received: from remotemail by yantan.tethera.net with local (Exim 4.80)
\r
23 (envelope-from <bremner@tethera.net>)
\r
24 id 1W8BHY-000369-Fh; Tue, 28 Jan 2014 12:13:00 -0400
\r
25 Received: (nullmailer pid 15962 invoked by uid 1000); Tue, 28 Jan 2014
\r
27 From: David Bremner <david@tethera.net>
\r
28 To: notmuch@notmuchmail.org
\r
29 Subject: [RFC Patch v2 1/2] doc: start of sphinx based docs
\r
30 Date: Tue, 28 Jan 2014 12:12:37 -0400
\r
31 Message-Id: <1390925558-15873-2-git-send-email-david@tethera.net>
\r
32 X-Mailer: git-send-email 1.8.5.2
\r
33 In-Reply-To: <1390925558-15873-1-git-send-email-david@tethera.net>
\r
34 References: <87vbxfkdex.fsf@zancas.localnet>
\r
35 <1390925558-15873-1-git-send-email-david@tethera.net>
\r
37 Content-Type: text/plain; charset=UTF-8
\r
38 Content-Transfer-Encoding: 8bit
\r
39 X-BeenThere: notmuch@notmuchmail.org
\r
40 X-Mailman-Version: 2.1.13
\r
42 List-Id: "Use and development of the notmuch mail system."
\r
43 <notmuch.notmuchmail.org>
\r
44 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
45 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
46 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
47 List-Post: <mailto:notmuch@notmuchmail.org>
\r
48 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
49 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
50 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
51 X-List-Received-Date: Tue, 28 Jan 2014 16:13:11 -0000
\r
53 This is the output from sphinx-quickstart, massaged a bit, along with
\r
54 a few sample docs converted to rst.
\r
58 doc/Makefile.local | 28 +++++
\r
59 doc/conf.py | 91 +++++++++++++++
\r
60 doc/index.rst | 24 ++++
\r
61 doc/notmuch-emacs.rst | 188 +++++++++++++++++++++++++++++++
\r
62 doc/notmuch-search-terms.rst | 255 +++++++++++++++++++++++++++++++++++++++++++
\r
63 doc/notmuch-search.rst | 203 ++++++++++++++++++++++++++++++++++
\r
64 doc/notmuch.rst | 173 +++++++++++++++++++++++++++++
\r
65 9 files changed, 968 insertions(+), 1 deletion(-)
\r
66 create mode 100644 doc/Makefile
\r
67 create mode 100644 doc/Makefile.local
\r
68 create mode 100644 doc/conf.py
\r
69 create mode 100644 doc/index.rst
\r
70 create mode 100644 doc/notmuch-emacs.rst
\r
71 create mode 100644 doc/notmuch-search-terms.rst
\r
72 create mode 100644 doc/notmuch-search.rst
\r
73 create mode 100644 doc/notmuch.rst
\r
75 diff --git a/Makefile b/Makefile
\r
76 index 0428160..39f0e62 100644
\r
79 @@ -5,7 +5,7 @@ all:
\r
80 # List all subdirectories here. Each contains its own Makefile.local.
\r
81 # Use of '=', without '+=', seems to be required for out-of-tree
\r
83 -subdirs = compat completion emacs lib man parse-time-string performance-test util test
\r
84 +subdirs = compat completion doc emacs lib man parse-time-string performance-test util test
\r
86 # We make all targets depend on the Makefiles themselves.
\r
87 global_deps = Makefile Makefile.config Makefile.local \
\r
88 diff --git a/doc/Makefile b/doc/Makefile
\r
89 new file mode 100644
\r
90 index 0000000..fa25832
\r
99 diff --git a/doc/Makefile.local b/doc/Makefile.local
\r
100 new file mode 100644
\r
101 index 0000000..d2a339b
\r
103 +++ b/doc/Makefile.local
\r
105 +# Makefile for Sphinx documentation
\r
110 +# You can set these variables from the command line.
\r
111 +SPHINXOPTS := -q -c $(dir)
\r
112 +SPHINXBUILD = sphinx-build
\r
113 +BUILDDIR := $(dir)/_build
\r
115 +# Internal variables.
\r
116 +ALLSPHINXOPTS := -d $(BUILDDIR)/doctrees $(SPHINXOPTS) $(dir)
\r
118 +.PHONY: help clean html man texinfo info
\r
121 + $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
\r
124 + $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
\r
127 + $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
\r
130 + make -C $(BUILDDIR)/texinfo info
\r
132 +CLEAN := $(CLEAN) $(dir)/_build
\r
133 diff --git a/doc/conf.py b/doc/conf.py
\r
134 new file mode 100644
\r
135 index 0000000..9170920
\r
139 +# -*- coding: utf-8 -*-
\r
144 +# -- General configuration ------------------------------------------------
\r
146 +# Add any Sphinx extension module names here, as strings. They can be
\r
147 +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
\r
151 +# Add any paths that contain templates here, relative to this directory.
\r
152 +templates_path = ['_templates']
\r
154 +# The suffix of source filenames.
\r
155 +source_suffix = '.rst'
\r
157 +# The master toctree document.
\r
158 +master_doc = 'index'
\r
160 +# General information about the project.
\r
161 +project = u'notmuch'
\r
162 +copyright = u'2014, Carl Worth and many others'
\r
164 +# The short X.Y version.
\r
166 +# The full version, including alpha/beta/rc tags.
\r
169 +# List of patterns, relative to source directory, that match files and
\r
170 +# directories to ignore when looking for source files.
\r
171 +exclude_patterns = ['_build']
\r
173 +# The name of the Pygments (syntax highlighting) style to use.
\r
174 +pygments_style = 'sphinx'
\r
176 +# -- Options for HTML output ----------------------------------------------
\r
178 +# The theme to use for HTML and HTML Help pages. See the documentation for
\r
179 +# a list of builtin themes.
\r
180 +html_theme = 'default'
\r
183 +# Add any paths that contain custom static files (such as style sheets) here,
\r
184 +# relative to this directory. They are copied after the builtin static files,
\r
185 +# so a file named "default.css" will overwrite the builtin "default.css".
\r
186 +html_static_path = ['_static']
\r
188 +# Output file base name for HTML help builder.
\r
189 +htmlhelp_basename = 'notmuchdoc'
\r
191 +# -- Options for manual page output ---------------------------------------
\r
193 +# One entry per manual page. List of tuples
\r
194 +# (source start file, name, description, authors, manual section).
\r
196 + ('notmuch', 'notmuch', u'thread-based email index, search, and tagging',
\r
197 + [u'Carl Worth and many others'], 1),
\r
198 + ('notmuch-search', 'notmuch-search', u'search the notmuch mail index',
\r
199 + [u'Carl Worth and many others'], 1),
\r
200 + ('notmuch-search-terms', 'notmuch-search-terms', u'query format for notmuch',
\r
201 + [u'Carl Worth and many others'], 7),
\r
205 +# If true, show URL addresses after external links.
\r
206 +#man_show_urls = False
\r
208 +# -- Options for Texinfo output -------------------------------------------
\r
210 +# Grouping the document tree into Texinfo files. List of tuples
\r
211 +# (source start file, target name, title, author,
\r
212 +# dir menu entry, description, category)
\r
213 +texinfo_documents = [
\r
214 + ('notmuch', 'notmuch', u'notmuch Documentation',
\r
215 + u'Carl Worth and many others', 'notmuch', 'thread-based email index, search and tagging',
\r
216 + 'Miscellaneous'),
\r
217 + ('notmuch-emacs', 'notmuch-emacs', u'notmuch Documentation',
\r
218 + u'Carl Worth and many others', 'notmuch-emacs', 'emacs based front-end for notmuch',
\r
219 + 'Miscellaneous'),
\r
220 + ('notmuch-search', 'notmuch-search', u'notmuch Documentation',
\r
221 + u'Carl Worth and many others', 'notmuch-search', 'search the notmuch mail index.',
\r
222 + 'Miscellaneous'),
\r
223 + ('notmuch-search-terms', 'notmuch-search-terms', u'notmuch Documentation',
\r
224 + u'Carl Worth and many others', 'notmuch-search-terms', 'query syntax for notmuch.',
\r
225 + 'Miscellaneous'),
\r
228 +# If true, do not generate a @detailmenu in the "Top" node's menu.
\r
229 +texinfo_no_detailmenu = True
\r
230 diff --git a/doc/index.rst b/doc/index.rst
\r
231 new file mode 100644
\r
232 index 0000000..c05c855
\r
234 +++ b/doc/index.rst
\r
236 +.. notmuch documentation master file, created by
\r
237 + sphinx-quickstart on Fri Jan 17 22:34:14 2014.
\r
238 + You can adapt this file completely to your liking, but it should at least
\r
239 + contain the root `toctree` directive.
\r
241 +Welcome to notmuch's documentation!
\r
242 +===================================
\r
252 + notmuch-search-terms
\r
254 +Indices and tables
\r
255 +==================
\r
260 diff --git a/doc/notmuch-emacs.rst b/doc/notmuch-emacs.rst
\r
261 new file mode 100644
\r
262 index 0000000..283bf69
\r
264 +++ b/doc/notmuch-emacs.rst
\r
269 +This manual covers only the emacs interface to notmuch. For information
\r
270 +on the command line interface, see See section “Description” in Notmuch
\r
271 +Manual Pager. To save typing, we will sometimes use *notmuch* in this
\r
272 +manual to refer to the Emacs interface to notmuch. If the distinction
\r
273 +should every be important, we’ll refer to the Emacs inteface as
\r
276 +Notmuch-emacs is highly customizable via the the Emacs customization
\r
277 +framework (or just by setting the appropriate variables). We try to
\r
278 +point out relevant variables in this manual, but in order to avoid
\r
279 +duplication of information, but you can usually find the most detailed
\r
280 +description in the varables docstring.
\r
286 + single: notmuch-hello
\r
289 +``notmuch-hello`` is the main entry point for notmuch. You can start it
\r
290 +with ``M-x notmuch`` or ``M-x notmuch-hello``. The startup screen looks
\r
291 +something like the following. There are some hints at the bottom of the
\r
292 +screen. There are three main parts to the notmuch-hello screen,
\r
293 +discussed below. The **bold** text indicates buttons you can click with
\r
294 +a mouse or by positioning the cursor and pressing ``<return>``
\r
296 +| Welcome to **notmuch** You have 52 messages.
\r
298 +| Saved searches: **[edit]**
\r
300 +| 52 **inbox** 52 **unread**
\r
302 +| Search: ____________________________________
\r
304 +| All tags: **[show]**
\r
306 +| Type a search query and hit RET to view matching threads.
\r
307 +| Edit saved searches with the ``edit`` button.
\r
308 +| Hit RET or click on a saved search or tag name to view matching threads.
\r
309 +| ``=`` to refresh this screen. ``s`` to search messages. ``q`` to quit.
\r
310 +| **Customize** this page.
\r
312 +You can change the overall appearence of the notmuch-hello screen by
\r
313 +customizing the variable :index:`notmuch-hello-sections`.
\r
317 +notmuch-hello key bindings
\r
318 +--------------------------
\r
321 + Move to the next widget (button or text entry field)
\r
324 + Move to the previous widget.
\r
327 + Activate the current widget.
\r
330 + Refresh the buffer; mainly update the counts of messages for various
\r
334 + Import mail, See :ref:`importing`
\r
337 + Compose a message
\r
340 + Search the notmuch database using :ref:`notmuch-search`
\r
343 + Print notmuch version
\r
348 +.. _saved-searches:
\r
353 +Notmuch replaces the static assignment of messages with the more dynamic
\r
354 +notion of searching. Notmuch-hello presents the user with a customizable
\r
355 +set of saved searchs. The initial defaults are ``tag:inbox`` and
\r
356 +``tag:unread``, but you can customize the following variables
\r
358 +:index:`notmuch-saved-searches`
\r
359 + A list of cons pairs, the first being the name to display, the
\r
360 + second being a query string for notmuch. See section “Description”
\r
361 + in Notmuch Query Syntax.
\r
363 +:index:`notmuch-saved-searches-sort-function`
\r
364 + This variable controls how saved searches should be sorted. A value
\r
365 + of ``nil`` displays the saved searches in the order they are stored
\r
366 + in ‘notmuch-saved-searches’.
\r
368 +:index:`notmuch-column-control`
\r
369 + Controls the number of columns for displaying saved-searches/tags
\r
374 +The search box lets the user enter an notmuch query. See section
\r
375 +“Description” in Notmuch Query Syntax, for more info on notmuch query
\r
376 +syntax. A history of recent searches is also displayed by default. The
\r
377 +latter is controlled by the variable :index:`notmuch-hello-recent-searches-max`.
\r
382 +One special kind of saved search provided by default is for each
\r
383 +individual tag defined in the database. This can be controlled via the
\r
384 +following variables.
\r
386 +:index:`notmuch-hello-tag-list-make-query`
\r
387 + Control how to construct a search (“virtual folder”) from a given
\r
390 +:index:`notmuch-hello-hide-tags`
\r
391 + Which tags not to display at all.
\r
393 +:index:`notmuch-column-control`
\r
394 + Controls the number of columns for displaying saved-searches/tags
\r
396 +.. _notmuch-search:
\r
401 +``notmuch-search-mode`` is used to display the results from executing
\r
402 +a query via ``notmuch-search``. The syntax for these queries is the
\r
403 +the same as :ref:`saved-searches`. For details of this syntax see
\r
404 +info:notmuch-search-terms
\r
406 +By default the output approximates that of the command line See section
\r
407 +“Description” in notmuch search command.
\r
409 +The main purpose of the ``notmuch-search-mode`` buffer is to act as a
\r
410 +menu of results that the user can explore further by pressing
\r
411 +``<return>`` on the appropriate line.
\r
414 + Move to next line
\r
417 + Move to previous line
\r
420 + Open thread on current line in :ref:`notmuch-show` mode
\r
423 + Display full set of key bindings
\r
425 +The presentation of results can be controlled by the following
\r
428 +:index:`notmuch-search-result-format`
\r
429 + Control how each thread of messages is presented in the
\r
430 + ``notmuch-show-mode`` buffer
\r
432 +:index:`notmuch-search-oldest-first`
\r
433 + Display the oldest threads at the top of the buffer
\r
451 +:index:`notmuch-poll`
\r
453 +:index:`notmuch-poll-script`
\r
454 diff --git a/doc/notmuch-search-terms.rst b/doc/notmuch-search-terms.rst
\r
455 new file mode 100644
\r
456 index 0000000..7885c6a
\r
458 +++ b/doc/notmuch-search-terms.rst
\r
460 +====================
\r
461 +notmuch-search-terms
\r
462 +====================
\r
469 +\ **notmuch**\ \ **count**\ [\ *options...*\ ] <\ *search-term*\ >...
\r
471 +\ **notmuch**\ \ **dump**\ [ <\ *filename*\ > ] [--] [ <\ *search-term*\ >...]
\r
473 +\ **notmuch**\ \ **search**\ [\ *options*\ ...] <\ *search-term*\ >...
\r
475 +\ **notmuch**\ \ **show**\ [\ *options*\ ...] <\ *search-term*\ >...
\r
477 +\ **notmuch**\ \ **tag**\ +<\ *tag*\ >|-<\ *tag*\ > [...] [--] <\ *search-term*\ >...
\r
485 +Several notmuch commands accept a common syntax for search terms.
\r
487 +The search terms can consist of free-form text (and quoted phrases)
\r
488 +which will match all messages that contain all of the given
\r
489 +terms/phrases in the body, the subject, or any of the sender or
\r
490 +recipient headers.
\r
492 +As a special case, a search string consisting of exactly a single
\r
493 +asterisk ("\*") will match all messages.
\r
495 +In addition to free text, the following prefixes can be used to force
\r
496 +terms to match against specific portions of an email, (where <brackets>
\r
497 +indicate user-supplied values):
\r
499 +from:<name-or-address>
\r
501 +to:<name-or-address>
\r
503 +subject:<word-or-quoted-phrase>
\r
507 +tag:<tag> (or is:<tag>)
\r
511 +thread:<thread-id>
\r
513 +folder:<directory-path>
\r
515 +date:<since>..<until>
\r
517 +The \ **from:**\ prefix is used to match the name or address of the sender of
\r
520 +The \ **to:**\ prefix is used to match the names or addresses of any recipient
\r
521 +of an email message, (whether To, Cc, or Bcc).
\r
523 +Any term prefixed with \ **subject:**\ will match only text from the subject
\r
524 +of an email. Searching for a phrase in the subject is supported by
\r
525 +including quotation marks around the phrase, immediately following
\r
528 +The \ **attachment:**\ prefix can be used to search for specific filenames (or
\r
529 +extensions) of attachments to email messages.
\r
531 +For \ **tag:**\ and \ **is:**\ valid tag values include \ **inbox**\ and \ **unread**\ by default
\r
532 +for new messages added by \ **notmuch**\ \ **new**\ as well as any other tag values
\r
533 +added manually with \ **notmuch**\ \ **tag**\ .
\r
535 +For \ **id:**\ , message ID values are the literal contents of the Message-ID:
\r
536 +header of email messages, but without the \`<', \`>' delimiters.
\r
538 +The \ **thread:**\ prefix can be used with the thread ID values that are
\r
539 +generated internally by notmuch (and do not appear in email messages).
\r
540 +These thread ID values can be seen in the first column of output from
\r
541 +\ **notmuch**\ \ **search**\
\r
543 +The \ **folder:**\ prefix can be used to search for email message files that
\r
544 +are contained within particular directories within the mail store. If
\r
545 +the same email message has multiple message files associated with it,
\r
546 +it's sufficient for a match that at least one of the files is contained
\r
547 +within a matching directory. Only the directory components below the
\r
548 +top-level mail database path are available to be searched.
\r
550 +The \ **date:**\ prefix can be used to restrict the results to only messages
\r
551 +within a particular time range (based on the Date: header) with a range
\r
554 +date:<since>..<until>
\r
556 +See \ **DATE**\ \ **AND**\ \ **TIME**\ \ **SEARCH**\ below for details on the range expression, and
\r
557 +supported syntax for <since> and <until> date and time expressions.
\r
559 +The time range can also be specified using timestamps with a syntax of:
\r
561 +<initial-timestamp>..<final-timestamp>
\r
563 +Each timestamp is a number representing the number of seconds since
\r
564 +1970-01-01 00:00:00 UTC.
\r
566 +In addition to individual terms, multiple terms can be combined with
\r
567 +Boolean operators ( \ **and**\ , \ **or**\ , \ **not**\ , etc.). Each term in the query will
\r
568 +be implicitly connected by a logical AND if no explicit operator is
\r
569 +provided, (except that terms with a common prefix will be implicitly
\r
570 +combined with OR until we get Xapian defect #402 fixed).
\r
572 +Parentheses can also be used to control the combination of the Boolean
\r
573 +operators, but will have to be protected from interpretation by the
\r
574 +shell, (such as by putting quotation marks around any parenthesized
\r
578 +********************
\r
579 +Date and Time Search
\r
580 +********************
\r
583 +notmuch understands a variety of standard and natural ways of
\r
584 +expressing dates and times, both in absolute terms ("2012-10-24") and
\r
585 +in relative terms ("yesterday"). Any number of relative terms can be
\r
586 +combined ("1 hour 25 minutes") and an absolute date/time can be
\r
587 +combined with relative terms to further adjust it. A non-exhaustive
\r
588 +description of the syntax supported for absolute and relative terms is
\r
591 +\ **The**\ \ **range**\ \ **expression**\
\r
593 +date:<since>..<until>
\r
595 +The above expression restricts the results to only messages
\r
596 +from <since> to <until>, based on the Date: header.
\r
598 +<since> and <until> can describe imprecise times, such as
\r
599 +"yesterday". In this case, <since> is taken as the earliest
\r
600 +time it could describe (the beginning of yesterday) and <until>
\r
601 +is taken as the latest time it could describe (the end of
\r
602 +yesterday). Similarly, date:january..february matches from the
\r
603 +beginning of January to the end of February.
\r
605 +Currently, we do not support spaces in range expressions. You
\r
606 +can replace the spaces with \`_', or (in most cases) \`-', or (in
\r
607 +some cases) leave the spaces out altogether. Examples in this
\r
608 +man page use spaces for clarity.
\r
610 +Open-ended ranges are supported (since Xapian 1.2.1), i.e. it's
\r
611 +possible to specify date:..<until> or date:<since>.. to not
\r
612 +limit the start or end time, respectively. Pre-1.2.1 Xapian
\r
613 +does not report an error on open ended ranges, but it does not
\r
614 +work as expected either.
\r
616 +Entering date:expr without ".." (for example date:yesterday)
\r
617 +won't work, as it's not interpreted as a range expression at
\r
618 +all. You can achieve the expected result by duplicating the
\r
619 +expr both sides of ".." (for example
\r
620 +date:yesterday..yesterday).
\r
622 +\ **Relative**\ \ **date**\ \ **and**\ \ **time**\
\r
624 +(years|months|weeks|days|hours|hrs|minutes|mins|seconds|secs)
\r
627 +All refer to past, can be repeated and will be accumulated.
\r
629 +Units can be abbreviated to any length, with the otherwise
\r
630 +ambiguous single m being m for minutes and M for months.
\r
632 +Number can also be written out one, two, ..., ten, dozen,
\r
633 +hundred. Additionally, the unit may be preceded by "last" or
\r
634 +"this" (e.g., "last week" or "this month").
\r
636 +When combined with absolute date and time, the relative date
\r
637 +and time specification will be relative from the specified
\r
638 +absolute date and time.
\r
640 +Examples: 5M2d, two weeks
\r
642 +\ **Supported**\ \ **absolute**\ \ **time**\ \ **formats**\
\r
643 +H[H]:MM[:SS] [(am|a.m.|pm|p.m.)]
\r
645 +H[H] (am|a.m.|pm|p.m.)
\r
658 +Examples: 17:05, 5pm
\r
660 +\ **Supported**\ \ **absolute**\ \ **date**\ \ **formats**\
\r
672 +M[M]/D[D][/[YY]YY]
\r
680 +D[D].M[M][.[YY]YY]
\r
684 +D[D][(st|nd|rd|th)] Mon[thname] [YYYY]
\r
686 +Mon[thname] D[D][(st|nd|rd|th)] [YYYY]
\r
690 +Month names can be abbreviated at three or more characters.
\r
692 +Weekday names can be abbreviated at three or more characters.
\r
694 +Examples: 2012-07-31, 31-07-2012, 7/31/2012, August 3
\r
696 +\ **Time**\ \ **zones**\
\r
704 +Some time zone codes, e.g. UTC, EET.
\r
712 +notmuch(1), notmuch-config(1), notmuch-count(1), notmuch-dump(1),
\r
713 +notmuch-hooks(5), notmuch-insert(1), notmuch-new(1), notmuch-reply(1),
\r
714 +notmuch-restore(1), notmuch-search(1), notmuch-show(1), notmuch-tag(1)
\r
715 diff --git a/doc/notmuch-search.rst b/doc/notmuch-search.rst
\r
716 new file mode 100644
\r
717 index 0000000..deb7e8b
\r
719 +++ b/doc/notmuch-search.rst
\r
731 +\ **notmuch**\ \ **search**\ [\ *options*\ ...] <\ *search-term*\ >...
\r
739 +Search for messages matching the given search terms, and display as
\r
740 +results the threads containing the matched messages.
\r
742 +The output consists of one line per thread, giving a thread ID, the
\r
743 +date of the newest (or oldest, depending on the sort option) matched
\r
744 +message in the thread, the number of matched messages and total
\r
745 +messages in the thread, the names of all participants in the thread,
\r
746 +and the subject of the newest (or oldest) message.
\r
748 +See notmuch-search-terms(7) for details of the supported syntax for
\r
751 +Supported options for \ **search**\ include
\r
754 + **--format=** ( **json** | **sexp** | **text** | **text0** )
\r
758 +Presents the results in either JSON, S-Expressions, newline
\r
759 +character separated plain-text (default), or null character
\r
760 +separated plain-text (compatible with xargs(1) -0 option where
\r
764 +\ **--format-version=N**\
\r
768 +Use the specified structured output format version. This is
\r
769 +intended for programs that invoke notmuch(1) internally. If
\r
770 +omitted, the latest supported version will be used.
\r
773 +\ **--output=(summary|threads|messages|files|tags)**\
\r
779 +Output a summary of each thread with any message matching
\r
780 +the search terms. The summary includes the thread ID, date,
\r
781 +the number of messages in the thread (both the number
\r
782 +matched and the total number), the authors of the thread
\r
787 +Output the thread IDs of all threads with any message
\r
788 +matching the search terms, either one per line
\r
789 +(--format=text), separated by null characters
\r
790 +(--format=text0), as a JSON array (--format=json), or an S-
\r
791 +Expression list (--format=sexp).
\r
795 +Output the message IDs of all messages matching the search
\r
796 +terms, either one per line (--format=text), separated by
\r
797 +null characters (--format=text0), as a JSON array
\r
798 +(--format=json), or as an S-Expression list
\r
803 +Output the filenames of all messages matching the search
\r
804 +terms, either one per line (--format=text), separated by
\r
805 +null characters (--format=text0), as a JSON array
\r
806 +(--format=json), or as an S-Expression list
\r
809 +Note that each message may have multiple filenames
\r
810 +associated with it. All of them are included in the
\r
811 +output, unless limited with the --duplicate=N option.
\r
815 +Output all tags that appear on any message matching the
\r
816 +search terms, either one per line (--format=text),
\r
817 +separated by null characters (--format=text0), as a JSON
\r
818 +array (--format=json), or as an S-Expression list
\r
822 +\ **--sort=** (\ **newest-first** | **oldest-first** )
\r
826 +This option can be used to present results in either
\r
827 +chronological order (\ **oldest-first**\ ) or reverse chronological
\r
828 +order (\ **newest-first**\ ).
\r
830 +Note: The thread order will be distinct between these two
\r
831 +options (beyond being simply reversed). When sorting by
\r
832 +\ **oldest-first**\ the threads will be sorted by the oldest message
\r
833 +in each thread, but when sorting by \ **newest-first**\ the threads
\r
834 +will be sorted by the newest message in each thread.
\r
836 +By default, results will be displayed in reverse chronological
\r
837 +order, (that is, the newest results will be displayed first).
\r
840 +\ **--offset=[-]N**\
\r
844 +Skip displaying the first N results. With the leading \`-',
\r
845 +start at the Nth result from the end.
\r
852 +Limit the number of displayed results to N.
\r
855 +\ **--exclude=(true|false|all|flag)**\
\r
859 +A message is called "excluded" if it matches at least one tag
\r
860 +in search.tag_exclude that does not appear explicitly in the
\r
861 +search terms. This option specifies whether to omit excluded
\r
862 +messages in the search process.
\r
864 +The default value, \ **true**\ , prevents excluded messages from
\r
865 +matching the search terms.
\r
867 +\ **all**\ additionally prevents excluded messages from appearing in
\r
868 +displayed results, in effect behaving as though the excluded
\r
869 +messages do not exist.
\r
871 +\ **false**\ allows excluded messages to match search terms and appear
\r
872 +in displayed results. Excluded messages are still marked in the
\r
875 +\ **flag**\ only has an effect when \ **--output=summary**\ . The output is
\r
876 +almost identical to \ **false**\ , but the "match count" is the number
\r
877 +of matching non-excluded messages in the thread, rather than
\r
878 +the number of matching messages.
\r
881 +\ **--duplicate=N**\
\r
885 +Effective with \ **--output=files**\ , output the Nth filename
\r
886 +associated with each message matching the query (N is 1-based).
\r
887 +If N is greater than the number of files associated with the
\r
888 +message, don't print anything.
\r
890 +Note that this option is orthogonal with the \ **folder:**\ search
\r
891 +prefix. The prefix matches messages based on filenames. This
\r
892 +option filters filenames of the matching messages.
\r
900 +This command supports the following special exit status codes
\r
905 + The requested format version is too old.
\r
910 + The requested format version is too new.
\r
921 +notmuch(1), notmuch-config(1), notmuch-count(1), notmuch-dump(1),
\r
922 +notmuch-hooks(5), notmuch-insert(1), notmuch-new(1), notmuch-reply(1),
\r
923 +notmuch-restore(1), notmuch-search-terms(7), notmuch-show(1), notmuchtag(1)
\r
924 diff --git a/doc/notmuch.rst b/doc/notmuch.rst
\r
925 new file mode 100644
\r
926 index 0000000..9d9a35c
\r
928 +++ b/doc/notmuch.rst
\r
938 +\ **notmuch**\ [\ *option*\ ...] \ *command*\ [\ *arg*\ ...]
\r
945 +Notmuch is a command-line based program for indexing, searching,
\r
946 +reading, and tagging large collections of email messages.
\r
948 +This page describes how to get started using notmuch from the command
\r
949 +line, and gives a brief overview of the commands available. For more
\r
950 +information on e.g. \ **notmuch**\ \ **show**\ consult the notmuch-show(1) man page,
\r
951 +also accessible via \ **notmuch**\ \ **help**\ \ **show**\
\r
953 +The quickest way to get started with Notmuch is to simply invoke the
\r
954 +\ **notmuch**\ command with no arguments, which will interactively guide you
\r
955 +through the process of indexing your mail.
\r
961 +While the command-line program \ **notmuch**\ provides powerful functionality,
\r
962 +it does not provide the most convenient interface for that
\r
963 +functionality. More sophisticated interfaces are expected to be built
\r
964 +on top of either the command-line interface, or more likely, on top of
\r
965 +the notmuch library interface. See http://notmuchmail.org for more
\r
966 +about alternate interfaces to notmuch. The emacs-based interface to
\r
967 +notmuch (available under \ **emacs/**\ in the Notmuch source distribution) is
\r
968 +probably the most widely used at this time.
\r
974 +Supported global options for \ **notmuch**\ include
\r
981 +Print a synopsis of available commands and exit.
\r
988 +Print the installed version of notmuch, and exit.
\r
991 +\ **--config=FILE**\
\r
995 +Specify the configuration file to use. This overrides any
\r
996 +configuration file specified by ${NOTMUCH_CONFIG}.
\r
1003 +The \ **notmuch**\ \ **setup**\ command is used to configure Notmuch for first use,
\r
1004 +(or to reconfigure it later).
\r
1006 +The setup command will prompt for your full name, your primary email
\r
1007 +address, any alternate email addresses you use, and the directory
\r
1008 +containing your email archives. Your answers will be written to a
\r
1009 +configuration file in ${NOTMUCH_CONFIG} (if set) or ${HOME}/.notmuch-
\r
1010 +config . This configuration file will be created with descriptive
\r
1011 +comments, making it easy to edit by hand later to change the
\r
1012 +configuration. Or you can run \ **notmuch**\ \ **setup**\ again to change the
\r
1015 +The mail directory you specify can contain any number of sub-
\r
1016 +directories and should primarily contain only files with individual
\r
1017 +email messages (eg. maildir or mh archives are perfect). If there are
\r
1018 +other, non-email files (such as indexes maintained by other email
\r
1019 +programs) then notmuch will do its best to detect those and ignore
\r
1022 +Mail storage that uses mbox format, (where one mbox file contains many
\r
1023 +messages), will not work with notmuch. If that's how your mail is
\r
1024 +currently stored, it is recommended you first convert it to maildir
\r
1025 +format with a utility such as mb2md before running \ **notmuch**\ \ **setup**\ \ **.**\
\r
1027 +Invoking \ **notmuch**\ with no command argument will run \ **setup**\ if the setup
\r
1028 +command has not previously been completed.
\r
1030 +\ **OTHER**\ \ **COMMANDS**\
\r
1031 +Several of the notmuch commands accept search terms with a common
\r
1032 +syntax. See notmuch-search-terms(7) for more details on the supported
\r
1035 +The \ **search**\ , \ **show**\ and \ **count**\ commands are used to query the email
\r
1038 +The \ **reply**\ command is useful for preparing a template for an email
\r
1041 +The \ **tag**\ command is the only command available for manipulating database
\r
1044 +The \ **dump**\ and \ **restore**\ commands can be used to create a textual dump of
\r
1045 +email tags for backup purposes, and to restore from that dump.
\r
1047 +The \ **config**\ command can be used to get or set settings int the notmuch
\r
1048 +configuration file.
\r
1055 +The following environment variables can be used to control the behavior
\r
1059 +\ **NOTMUCH_CONFIG**\
\r
1061 + Specifies the location of the notmuch configuration file.
\r
1062 + Notmuch will use ${HOME}/.notmuch-config if this variable is not
\r
1067 +\ **NOTMUCH_TALLOC_REPORT**\
\r
1069 + Location to write a talloc memory usage report. See
\r
1070 + \ **talloc_enable_leak_report_full**\ in talloc(3) for more
\r
1075 +\ **NOTMUCH_DEBUG_QUERY**\
\r
1077 + If set to a non-empty value, the notmuch library will print (to
\r
1078 + stderr) Xapian queries it constructs.
\r
1085 +notmuch-config(1), notmuch-count(1), notmuch-dump(1), notmuch-hooks(5),
\r
1086 +notmuch-insert(1), notmuch-new(1), notmuch-reply(1), notmuch-restore(1),
\r
1087 +notmuch-search(1), notmuch-search-terms(7), notmuch-show(1),
\r
1090 +The notmuch website: \ **http://notmuchmail.org**\
\r
1097 +Feel free to send questions, comments, or kudos to the notmuch mailing
\r
1098 +list <notmuch@notmuchmail.org> . Subscription is not required before
\r
1099 +posting, but is available from the notmuchmail.org website.
\r
1101 +Real-time interaction with the Notmuch community is available via IRC
\r
1102 +(server: irc.freenode.net, channel: #notmuch).
\r