Hello. I noticed one of the home-manager modules has an incorrect config option. Can I use an overlay to fix it? I tried this:
nixpkgs.overlays = [
(self: super: {
hm-modules.programs.navi = super.hm-modules.programs.navi.override {
configDir = self.config.xdg.configHome;
};
})
];
But I see an error in the console saying that says: This will soon not be possible. Please remove all nixpkgsoptions when usinghome-manager.useGlobalPkgs.
1 Like
Overlays are for packages, not modules. There’s also no option configDir
in this module.
You can copy the module, add the original module path to disabledModules
, and add your new module to imports
.
But I don’t see the benefit to set it to the value it already has? (Unless you’re on darwin)
This is the workaround I came up with, it is working:
#set navi settings to the same value passed to the module
navi = {
enable = true;
enableZshIntegration = true;
enableBashIntegration = true;
settings = navi-settings;
};
};
# My temporal fix until https://github.com/nix-community/home-manager/issues/6559
home.file."${config.xdg.configHome}/navi/config.yaml".source =
(yamlFormat.generate "navi-config" navi-settings);
So, I am basically manually pointing to the same file the module is generating but at the desired path.
I am indeed on darwin
How do I add the original path to disabled modules?