From 905aa1c05ff4657e61556550a672db348ee9fca8 Mon Sep 17 00:00:00 2001 From: drewry pope Date: Tue, 22 Aug 2023 16:27:55 -0500 Subject: [PATCH 1/3] feat(flake): add overlays --- flake.nix | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index ed7193a..d3e531a 100644 --- a/flake.nix +++ b/flake.nix @@ -4,7 +4,7 @@ utils.url = "github:numtide/flake-utils"; }; - outputs = { self, nixpkgs, utils }: + outputs = { self, nixpkgs, utils, ... }: utils.lib.eachDefaultSystem (system: let pkgs = import nixpkgs { @@ -58,5 +58,16 @@ ]; RUST_SRC_PATH = "${pkgs.rust.packages.stable.rustPlatform.rustLibSrc}"; }; - }); + }) + // { + overlays = { + default = final: prev: { + nix-software-center = self.packages.${final.system}.nix-software-center; + }; + pkgs = final: prev: { + nixSoftwareCenterPkgs = self.packages.${prev.system}; + }; + }; + overlay = self.overlays.default; + }; } From 3cb56cfacd6ff75f69991bd3eb7328008db73753 Mon Sep 17 00:00:00 2001 From: drewry pope Date: Tue, 22 Aug 2023 16:29:01 -0500 Subject: [PATCH 2/3] chore(flake): update lock --- flake.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/flake.lock b/flake.lock index 8bc2f92..4b9f366 100644 --- a/flake.lock +++ b/flake.lock @@ -2,11 +2,11 @@ "nodes": { "nixpkgs": { "locked": { - "lastModified": 1686592866, - "narHash": "sha256-riGg89eWhXJcPNrQGcSwTEEm7CGxWC06oSX44hajeMw=", + "lastModified": 1692638711, + "narHash": "sha256-J0LgSFgJVGCC1+j5R2QndadWI1oumusg6hCtYAzLID4=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "0eeebd64de89e4163f4d3cf34ffe925a5cf67a05", + "rev": "91a22f76cd1716f9d0149e8a5c68424bb691de15", "type": "github" }, "original": { @@ -42,11 +42,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1685518550, - "narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=", + "lastModified": 1689068808, + "narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=", "owner": "numtide", "repo": "flake-utils", - "rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef", + "rev": "919d646de7be200f3bf08cb76ae1f09402b6f9b4", "type": "github" }, "original": { From dc9896bbb0e0f635935579097ebaababb80c5ccd Mon Sep 17 00:00:00 2001 From: drewry pope Date: Tue, 22 Aug 2023 16:32:41 -0500 Subject: [PATCH 3/3] feat(flake): align overlays with common patterns --- flake.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/flake.nix b/flake.nix index d3e531a..196c58c 100644 --- a/flake.nix +++ b/flake.nix @@ -61,13 +61,14 @@ }) // { overlays = { - default = final: prev: { + pkgs = final: prev: { nix-software-center = self.packages.${final.system}.nix-software-center; }; - pkgs = final: prev: { + nixSoftwareCenterPkgs = final: prev: { nixSoftwareCenterPkgs = self.packages.${prev.system}; }; + default = self.overlays.nixSoftwareCenterPkgs; }; - overlay = self.overlays.default; + overlay = self.overlays.pkgs; }; }