]> git.notmuchmail.org Git - notmuch/commit
cli/insert: add --world-readable flag
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Fri, 9 Feb 2018 04:10:58 +0000 (23:10 -0500)
committerDavid Bremner <david@tethera.net>
Sat, 24 Mar 2018 23:08:11 +0000 (20:08 -0300)
commitb6e3efde05ed72fa1b9c017093aaf56d70b533c1
tree2760adf0bc546aeef42228f1eb6931699003c7de
parent0cbe982bfd4516ee441ca5bbdd858616e54cc141
cli/insert: add --world-readable flag

In some cases (e.g. when building a publicly-visible e-mail archive)
it doesn't make any sense to restrict visibility of the message to the
current user account.

This adds a --world-readable boolean option for "notmuch insert", so
that those who want to archive their mail publicly can feed their
archiver with:

    notmuch insert --world-readable

Other local delivery agents (postfix's local, and dovecot's lda) all
default to delivery in mode 0600 rather than relying on the user's
umask, so this fix doesn't change the default.

Also, this does not override the user's umask.  if the umask is
already set tight, it will not become looser as the result of passing
--world-readable.

Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
doc/man1/notmuch-insert.rst
notmuch-insert.c
test/T070-insert.sh