diff --git a/flake.lock b/flake.lock index c569a80..de0a509 100644 --- a/flake.lock +++ b/flake.lock @@ -53,6 +53,24 @@ "type": "github" } }, + "flake-utils_2": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1731533236, + "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -165,6 +183,7 @@ "root": { "inputs": { "colmena": "colmena", + "flake-utils": "flake-utils_2", "home-manager": "home-manager", "nixos-config-hidden": "nixos-config-hidden", "nixos-hardware": "nixos-hardware", @@ -186,6 +205,21 @@ "repo": "nixpkgs", "type": "github" } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } } }, "root": "root", diff --git a/flake.nix b/flake.nix index 23a9555..1aa34b0 100644 --- a/flake.nix +++ b/flake.nix @@ -11,16 +11,18 @@ url = "git+ssh://git@github.com/henridoh/nixos-config-hidden"; inputs.nixpkgs.follows = "nixpkgs"; }; + flake-utils.url = "github:numtide/flake-utils"; }; outputs = { self, - nixpkgs, - nixos-hardware, colmena, + flake-utils, home-manager, nixos-config-hidden, + nixos-hardware, + nixpkgs, }@inputs: let lib = nixpkgs.lib; @@ -85,7 +87,17 @@ ]; }; }; - - formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-tree; - }; + } + // flake-utils.lib.eachDefaultSystem ( + system: + let + pkgs = import nixpkgs { inherit system; }; + in + { + devShells.withColmena = pkgs.mkShell { + buildInputs = [ colmena.packages.${system}.colmena ]; + }; + formatter = pkgs.nixfmt-tree; + } + ); }