NOTMUCH-COMPACT(1)
π
NOTMUCH-COMPACT(1) β the notmuch manual, bestie edition π
okay so like. this is the page for notmuch-compact, and it lives in the notmuch manual. yes it's a real whole manual. no I will not be normal about it.
β¨ NAME β¨
notmuch-compact β compact the notmuch database
π¦ SYNOPSIS π¦
notmuch compact [--quiet] [--backup=<directory>]
π DESCRIPTION π
so the compact command? it compacts the notmuch database. that's it, that's the vibe. and the glow-up is real: it can both shrink how much space the database is eating and make lookups faster. it's giving "spring cleaning but for your mail index". π§Ήβ¨
the compacted database gets built in a temporary directory, and then it's moved into the place of the original database. the original uncompacted database? discarded. gone. bye. unless you use the --backup=<directory> option, in which case you keep it. π«Ά
heads up bestie: the database write lock is held for the entire compaction process. and that process "may be quite long". so like, protect data integrity and all, but nobody else is writing while this is happening. plan accordingly. π
supported options for compact include:
--backup=<directory>β save the current database into the given directory before replacing it with the compacted database. two rules though, no cap: the backup directory must not exist, and it must live on the same mounted filesystem as the current database. π--quietβ do not report database compaction progress to stdout. silent mode. stealth mode. π€«
πΈ SEE ALSO πΈ
notmuch, notmuch-count, notmuch-dump, notmuch-hooks, notmuch-insert, notmuch-new, notmuch-reply, notmuch-restore, notmuch-search, notmuch-search-terms, notmuch-show, notmuch-tag
(go read them, they're all part of the squad π)
π Author π
Carl Worth and many others
β Copyright β
2009-2026, Carl Worth and many others
and that's the whole page, periodt π
this was version 0.40, dated Jan 31, 2026, coming at you straight from the notmuch source. now go compact something, bestie β responsibly. π¦π
π¦ where this page comes from
- fedora 44: notmuch 0.40-1.fc44 Β· GPL-3.0-or-later
- fedora 44: notmuch 0.40-1.fc44 Β· GPL-3.0-or-later
- nixos 26.05: notmuch 0.40
- ubuntu resolute: notmuch 0.40-1ubuntu1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms