MU-SERVER(1)
π NAME π
mu-server β the mu backend for the mu4e e-mail client.
Okay so first things first: this is the mu-server(1) page, from the General Commands Manual. It's giving "backend bestie who does all the work and gets zero credit". β¨
π¦ SYNOPSIS π¦
mu [COMMON-OPTIONS] server
πΈ DESCRIPTION πΈ
So mu server boots up a lil' simple shell where you can query and manipulate the mu database. Everything it says back to you comes out as s-expressions.
And ngl, mu server is not meant for humans β like, unless you're straight-up debugging. It's designed specifically for the mu4e e-mail client. It's not here to be your friend, it's here to serve. π
The shape of a command looks like this:
(<command-name> :param1 value1 :param2 value2)
For example, to view a certain message, the command would be:
(view :docid 12345)
Parameters can be sent in any order you like β freedom, love that for you β but they must be of the correct type though. No funny business. The full deets live in lib/utils/mu-sexp-parser.hh and lib/utils/mu-sexp-parser.cc in the source-tree. iykyk. π
π¬ OUTPUT FORMAT π¬
mu server accepts a number of commands, and delivers its results in the form:
\376<length>\377<s-expr>
So that's \376 (one byte 0xfe), followed by the length of the s-expression expressed as an hexadecimal number, followed by another \377 (one byte 0xff), followed by the actual s-expression. π
By prefixing the expression with its length, it can be processed more efficiently. And the \376 and \377 were chosen since they never occur in valid UTF-8 β which is what the s-expressions are encoded in. iconic, honestly. π₯
π SERVER OPTIONS π
β¨ --commands
List available commands (and try with --verbose).
β¨ --eval expression
Evaluate a mu4e server s-expression.
β¨ --allow-temp-file
If set, allow for the output of some commands to use temp-files rather than directly through the emacs process input/output. This is noticeably faster for commands with a lot of output, esp. when the temp-file uses a in-memory file-system. π
β¨ --listen
If set, the server starts an SCM REPL as well, which listens on a Unix domain socket. This corresponds to the --listen options for mu scm*.
The store object (including the Xapian database) is shared between the server and the REPL. Besties sharing everything. π«Ά
π PERFORMANCE π
As an indication for the relative performance, we can simulate something mu4e does. We take the overall time of 50 such requests:
time build/mu/mu server --allow-temp-file --eval '(find :query "\"\"" :include-related t :threads t :maxnum 50000)' >/dev/null
(and --allow-temp-file for 1.11)
Here's the glow-up, release by release:
- release
1.8β8.6s - release
1.10β5.7s - release
1.11 (master)β2.8s
the way that number kept droppingβ¦ ate and left no crumbs. ππ₯
π --muhome
Use a non-default directory to store and read the database, write the logs, etc. By default, mu uses the XDG Base Directory Specification (e.g. on GNU/Linux this defaults to ~/.cache/mu and ~/.config/mu). Earlier versions of mu defaulted to ~/.mu, which now requires --muhome=~/.mu. π
The environment variable MUHOME can be used as an alternative to --muhome. The latter has precedence.
π οΈ COMMON OPTIONS π οΈ
π -d, --debug
Makes mu generate extra debug information, useful for debugging the program itself. Debug information goes to the standard logging location; see mu(1).
π -q, --quiet
Causes mu not to output informational messages and progress information to standard output, but only to the log file. Error messages will still be sent to standard error.
Heads up bestie:mu indexis much faster with--quiet, so it is recommended you use this option when using mu from scripts etc. β¨
π --log-stderr
Causes mu to not output log messages to standard error, in addition to sending them to the standard logging location.
π --nocolor
Do not use ANSI colors. The environment variable NO_COLOR can be used as an alternative to --nocolor.
π -V, --version
Prints mu version and copyright information.
π -h, --help
Lists the various command line options.
π REPORTING BUGS π
Please report bugs at https://github.com/djcb/mu/issues.
π AUTHOR π
Dirk-Jan C. Binnema <djcb@djcbsoftware.nl>
π COPYRIGHT π
This manpage is part of mu 1.14.2.
Copyright Β© 2008-2026 Dirk-Jan C. Binnema. License GPLv3+: GNU GPL version 3 or later https://gnu.org/licenses/gpl.html. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. π
π SEE ALSO π
And that's a wrap on mu-server(1) β straight out of the General Commands Manual, part of mu 1.14.2, brought to you by your girl who read the whole page so you didn't have to. go query that database, you absolute icon. ππ¦πΈ
π¦ where this page comes from
- ubuntu stonking: maildir-utils 1.14.2-1 Β· 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