1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-30 06:59:45 +01:00

mu: fix command (#1623)

mu-cfind is meant to search for contacts within your contacts database and the emails that you have sent/received. The use of the --personal flag in that command is meant to filter for only emails that use your email addresses (which are all the ones you specify with the ${myAddresses} variable. Disregard what I said in #1623 (comment).

--my-address=<my-email-address>

    specifies that some e-mail addresses are 'my-address' (--my-address can be used multiple times).
    This is used by mu cfind -- any e-mail address found in the address fields of a message which also
    has <my-email-address> in one of its address fields is considered a personal e-mail address. This
    allows you, for example, to filter out (mu cfind --personal) addresses which were merely seen in
    mailing list messages.

To initialize the database with mu init, the ${myAddresses} is not required to be passed to successfully initialize the database, but it is heavily recommended to do so.

To see the difference, in a safe location, run mu init --maildir=<path>, then mu index. You'll notice that "personal addresses" returns <none>, although the database will still work. However, mu cfind --personal will fail (as the personal contacts don't exist). Then run mu init --maildir=<path> --my-address=<address>, then mu index. Then you'll be able to search for contacts using mu cfind --personal.
This commit is contained in:
MaxSchlueter 2021-01-19 18:36:31 +00:00 committed by GitHub
parent 8127799f79
commit 3fe2a57b95
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -50,7 +50,7 @@ in {
# In theory, mu is the only thing that creates that directory, and it is # In theory, mu is the only thing that creates that directory, and it is
# only created during the initial index. # only created during the initial index.
if [[ ! -d "${dbLocation}" ]]; then if [[ ! -d "${dbLocation}" ]]; then
$DRY_RUN_CMD mu init ${maildirOption} $VERBOSE_ARG; $DRY_RUN_CMD mu init ${maildirOption} ${myAddresses} $VERBOSE_ARG;
fi fi
''; '';
}; };