Closed RiscadoA closed 2 years ago
Couple thoughts:
impermanenceHome
home-manager.impermanence
.cc. @talyz
I can't really comment on whether this works, since I don't use flakes, but it looks fine to me. home-manager.impermanence
looks good.
Been using this one for a while, working nicely so far
Couple thoughts:
* Nix style is camelCase, so it should be `impermanenceHome` * I wonder if we just want to have it be in a sub-attr, so `home-manager.impermanence`.
cc. @talyz
I've changed it to match your suggestions.
I believe the home-manager community was working on standardizing this over at https://github.com/nix-community/home-manager/issues/1783, although it seems to have stalled.
How do I add this to my NixOS configuration flake? I've defined inputs.impermanence.url = "github:a12l/impermanence/master";
(my fork of nix-community/impermanence
with this patch applied), and added
home-manager.nixosModules.home-manager
{
home-manager.users.a12l = {
imports = [ impermanence ];
home.persistence."/persistent/home/a12l" = { };
}
}
to my NixOS configuration flake. But when I try to build it I get
$ nixos-rebuild build --flake '.#mobile-p-ep1'
building the system configuration...
error: The option `home-manager.users.a12l.home.persistence' does not exist. Definition values:
- In `/nix/store/480mp97jl7s8qy7m4plnq2v98qfzapma-source/flake.nix':
{
"/persistent/home/a12l" = { };
}
(use '--show-trace' to show detailed location information)
home-manager.nix
wasn't being added tonixosModules
onflake.nix
. Added it asimpermanence-home
.