Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mu: add support for setting muhome #5535

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

jdek
Copy link

@jdek jdek commented Jun 13, 2024

Description

The database path can be set by the user, this is useful for keeping
the Maildir and the Mu Xapian cache together without affecting
XDG_CACHE_HOME. Fixes #5534.

Note that this is untested apart from the test suite. I'm not entirely sure how to easily test a home-manager change when it's a module within my NixOS configuration temporarily.

Checklist

  • Change is backwards compatible.

  • Code formatted with ./format.

  • Code tested through nix-shell --pure tests -A run.all or nix develop --ignore-environment .#all using Flakes.

  • Test cases updated/added. See example.

  • Commit messages are formatted like

    {component}: {description}
    
    {long description}
    

    See CONTRIBUTING for more information and recent commit messages for examples.

  • If this PR adds a new module

    • Added myself as module maintainer. See example.

Maintainer CC

@Karljo

The database path can be set by the user, this is useful for keeping
the Maildir and the Mu Xapian cache together without affecting
XDG_CACHE_HOME

Fixes nix-community#5534.

Signed-off-by: J. Dekker <[email protected]>
@@ -31,6 +31,15 @@ in {

package = mkPackageOption pkgs "mu" { };

home = mkOption {
type = with types; nullOr str;
default = null;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe the default should be "${config.xdg.cacheHome}/mu" and --muhome always used? Note, if we do this then also need to add defaultText to avoid making documentation depend on the configuration.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like null to unset values such that the default is used, though maybe in the case of null we should just remove the --muhome argument entirely. That being said it doesn't matter to me either way, which would you prefer?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug: MUHOME not respected by mu activation
2 participants