From 38be7e937442c204f84fb8e3bfbcc421ff21b5e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20B=C3=A4dorf?= Date: Thu, 5 Oct 2023 10:44:48 +0200 Subject: [PATCH] refactor: rename alternative nixpkgs inputs --- flake.lock | 78 ++++++++++++++++++------------------- flake.nix | 6 +-- modules/default.nix | 27 ++++++------- overlays/signal-desktop.nix | 2 +- 4 files changed, 53 insertions(+), 60 deletions(-) diff --git a/flake.lock b/flake.lock index 0a1b3b9..1983625 100644 --- a/flake.lock +++ b/flake.lock @@ -273,22 +273,6 @@ "type": "github" } }, - "master": { - "locked": { - "lastModified": 1693817516, - "narHash": "sha256-nhmWHJhGutkDr7NMDoqPifsrLTcKLtWpX2m3F0hkiR0=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "8c27922a0e2de18f1fadb4f2bd65d5cb9de16b64", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "master", - "repo": "nixpkgs", - "type": "github" - } - }, "mobile-nixos": { "flake": false, "locked": { @@ -408,13 +392,45 @@ "type": "github" } }, - "nixpkgs_2": { + "nixpkgs-master": { "locked": { - "lastModified": 1696039360, - "narHash": "sha256-g7nIUV4uq1TOVeVIDEZLb005suTWCUjSY0zYOlSBsyE=", + "lastModified": 1696434248, + "narHash": "sha256-qivb3b3b5Cxe5/8qwCJ4CJCw/ENtim5zlhDItGR0p1I=", "owner": "nixos", "repo": "nixpkgs", - "rev": "32dcb45f66c0487e92db8303a798ebc548cadedc", + "rev": "349bdd9653c42f1793d338b43aefe08883c5ebee", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "master", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs-unstable": { + "locked": { + "lastModified": 1696193975, + "narHash": "sha256-mnQjUcYgp9Guu3RNVAB2Srr1TqKcPpRXmJf4LJk6KRY=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "fdd898f8f79e8d2f99ed2ab6b3751811ef683242", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1696323343, + "narHash": "sha256-u7WLUrh5eb+6SBYwtkaGL2ryHpLcHzmLml+a+VqKJWE=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "3b79cc4bcd9c09b5aa68ea1957c25e437dc6bc58", "type": "github" }, "original": { @@ -464,15 +480,15 @@ "flake-compat": "flake-compat", "flake-parts": "flake-parts", "home-manager": "home-manager", - "master": "master", "mobile-nixos": "mobile-nixos", "musnix": "musnix", "nix-darwin": "nix-darwin", "nixos-flake": "nixos-flake", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs_2", - "scan2paperless": "scan2paperless", - "unstable": "unstable" + "nixpkgs-master": "nixpkgs-master", + "nixpkgs-unstable": "nixpkgs-unstable", + "scan2paperless": "scan2paperless" } }, "scan2paperless": { @@ -556,22 +572,6 @@ "type": "github" } }, - "unstable": { - "locked": { - "lastModified": 1696019113, - "narHash": "sha256-X3+DKYWJm93DRSdC5M6K5hLqzSya9BjibtBsuARoPco=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "f5892ddac112a1e9b3612c39af1b72987ee5783a", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, "utils": { "locked": { "lastModified": 1667395993, diff --git a/flake.nix b/flake.nix index 685238a..d0c1605 100644 --- a/flake.nix +++ b/flake.nix @@ -6,7 +6,8 @@ inputs = { # Track channels with commits tested and built by hydra nixpkgs.url = "github:nixos/nixpkgs/nixos-23.05"; - unstable.url = "github:nixos/nixpkgs/nixos-unstable"; + nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable"; + nixpkgs-master.url = "github:nixos/nixpkgs/master"; flake-compat.url = "github:edolstra/flake-compat"; flake-compat.flake = false; @@ -33,7 +34,6 @@ mobile-nixos.url = "github:nixos/mobile-nixos"; mobile-nixos.flake = false; - master.url = "github:nixos/nixpkgs/master"; scan2paperless.url = "git+https://git.pub.solar/b12f/scan2paperless.git"; musnix.url = "github:musnix/musnix"; adblock-unbound.url = "github:MayNiklas/nixos-adblock-unbound"; @@ -66,8 +66,6 @@ inputs.agenix.overlays.default ]; }; - unstable = import inputs.unstable { inherit system; }; - master = import inputs.master { inherit system; }; }; devShells.default = pkgs.mkShell { diff --git a/modules/default.nix b/modules/default.nix index 22ceb87..9764f4c 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -36,27 +36,22 @@ inputs.agenix.nixosModules.default inputs.musnix.nixosModules.musnix - ({ - flake, - pkgs, - lib, - unstable, - master, - ... - }: { - nixpkgs.overlays = (import ../overlays) ++ [ + ({ flake, pkgs, lib, ... }: { + nixpkgs.overlays = [ (prev: next: { - scan2paperless = inputs.scan2paperless.legacyPackages.${prev.system}.scan2paperless; - nixd = inputs.unstable.legacyPackages.${prev.system}.nixd; + nixd = inputs.nixpkgs-unstable.legacyPackages.${prev.system}.nixd; - factorio-headless = inputs.master.legacyPackages.${prev.system}.factorio-headless; - paperless-ngx = inputs.master.legacyPackages.${prev.system}.paperless-ngx; - waybar = inputs.master.legacyPackages.${prev.system}.waybar; - element-desktop = inputs.master.legacyPackages.${prev.system}.element-desktop; + factorio-headless = inputs.nixpkgs-master.legacyPackages.${prev.system}.factorio-headless; + paperless-ngx = inputs.nixpkgs-master.legacyPackages.${prev.system}.paperless-ngx; + waybar = inputs.nixpkgs-master.legacyPackages.${prev.system}.waybar; + element-desktop = inputs.nixpkgs-master.legacyPackages.${prev.system}.element-desktop; + signal-desktop = inputs.nixpkgs-master.legacyPackages.${prev.system}.signal-desktop; + + scan2paperless = inputs.scan2paperless.legacyPackages.${prev.system}.scan2paperless; adlist = inputs.adblock-unbound.packages.${prev.system}; }) - ]; + ] ++ (import ../overlays); nix.nixPath = [ "nixpkgs=${inputs.nixpkgs}" diff --git a/overlays/signal-desktop.nix b/overlays/signal-desktop.nix index 54f9175..e29c7eb 100644 --- a/overlays/signal-desktop.nix +++ b/overlays/signal-desktop.nix @@ -2,7 +2,7 @@ final: prev: { signal-desktop = prev.signal-desktop.overrideAttrs (oldAttrs: rec { inherit (oldAttrs) pname; dir = "Signal"; - electron = prev.electron_24; + # electron = prev.electron_24; preFixup = '' gappsWrapperArgs+=(