I want to keep my bashrc as a stand-alone file, but still require some extra variables when using hm. But it seems it’s writing the same file.
{
programs.bash = {
enable = true;
sessionVariables = {
EDITOR = "nvim";
XDG_RUNTIME_DIR = "$HOME/.cache/";
};
};
home.file.".bashrc" = {
source = ../../dotfiles/.bashrc;
};
home.file.".inputrc" = {
source = ../../dotfiles/.inputrc;
};
}
error: The option `home.file.".bashrc".source' has conflicting definition values:
- In `/nix/store/n04dfzl1vr8vfgr0a8v7wcisq1qxiab5-source/modules/programs/bash.nix': <derivation bashrc>
- In `/nix/store/zq3wj9xz0pr64mza67ndhj7wvvm11wyc-source/packages/shell/bash.nix': /nix/store/zq3wj9xz0pr64mza67ndhj7wvvm11wyc-source/dotfiles/.bashrc
Use `lib.mkForce value` or `lib.mkDefault value` to change the priority on any of these definitions.