From da1b745ae60fa2532ef145337dba2a9ccb1cc95b Mon Sep 17 00:00:00 2001 From: Alejandro Soto Date: Sat, 20 Aug 2022 23:41:45 -0600 Subject: flake: add hm-isolation dependency --- flake.nix | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix index 5780813..bf1c8c5 100644 --- a/flake.nix +++ b/flake.nix @@ -10,10 +10,12 @@ nur.url = "github:nix-community/NUR"; impermanence.url = "github:nix-community/impermanence"; + hm-isolation.url = "/home/ale/hm-isolation"; }; outputs = - { self, nixpkgs, nixpkgsUnstable, home-manager, nur, impermanence, ... }: + { self, nixpkgs, nixpkgsUnstable, home-manager + , nur, impermanence, hm-isolation, ... }: with nixpkgs.lib; let util = import ./util; inherit (util nixpkgs.lib) importAll; @@ -38,14 +40,20 @@ in mapAttrs (_: hostConfig) (importAll { root = ./sys/platform; }); homeConfigurations = let + configuration = import ./home { + inherit self nixpkgs nixpkgsUnstable nur hm-isolation; + }; + + username = "ale"; + home = platform: home-manager.lib.homeManagerConfiguration { system = "x86_64-linux"; - configuration = import ./home { inherit self nixpkgs nixpkgsUnstable nur; }; + inherit configuration; extraModules = [ platform ]; - username = "ale"; - homeDirectory = "/home/ale"; + inherit username; + homeDirectory = "/home/${username}"; # Update the state version as needed. # See the changelog here: @@ -57,10 +65,10 @@ extraSpecialArgs = {}; }; - homeConfig = id: platform: { - name = "ale@${id}"; + platformHome = name: platform: { + name = "${username}@${name}"; value = home platform; }; - in mapAttrs' homeConfig (importAll { root = ./home/platform; }); + in mapAttrs' platformHome (importAll { root = ./home/platform; }); }; } -- cgit v1.2.3