about summary refs log tree commit diff stats
path: root/flake.nix
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--flake.nix117
1 files changed, 50 insertions, 67 deletions
diff --git a/flake.nix b/flake.nix
index 8d8ce03a..47b1b569 100644
--- a/flake.nix
+++ b/flake.nix
@@ -1,17 +1,22 @@
-# Copyright (C) 2024 Benedikt Peetz <benedikt.peetz@b-peetz.de>
+# nixos-config - My current NixOS configuration
 #
+# Copyright (C) 2024 Benedikt Peetz <benedikt.peetz@b-peetz.de>
+# Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de>
 # SPDX-License-Identifier: GPL-3.0-or-later
+#
+# This file is part of my nixos-config.
+#
+# You should have received a copy of the License along with this program.
+# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>.
 {
   description = "A NixOS System Configuration";
 
   inputs = {
     # base
-    nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-24.11";
+    nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-25.05";
     nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
 
     # open nixpkgs prs
-    # FIXME: Close these PRs <2024-09-07>
-    nixpkgs-lf.url = "github:bpeetz/nixpkgs/init-lf.nvim";
 
     library = {
       url = "git+https://git.foss-syndicate.org/vhack.eu/nix-library?ref=prime";
@@ -114,14 +119,6 @@
         nixpkgs.follows = "nixpkgs";
       };
     };
-    flake_version_update = {
-      url = "git+https://codeberg.org/soispha/flake_version_update.git";
-      inputs = {
-        systems.follows = "systems";
-        nixpkgs.follows = "nixpkgs";
-        flake-utils.follows = "flake-utils";
-      };
-    };
 
     # nixos modules
     home-manager = {
@@ -136,12 +133,13 @@
         nixpkgs.follows = "nixpkgs";
       };
     };
-    nixVim = {
+    nixvim = {
       url = "github:nix-community/nixvim";
       inputs = {
         flake-parts.follows = "flake-parts";
         nixpkgs.follows = "nixpkgs";
         nuschtosSearch.follows = "nuschtosSearch";
+        systems.follows = "systems";
       };
     };
     agenix = {
@@ -153,16 +151,6 @@
         systems.follows = "systems";
       };
     };
-    ragenix = {
-      url = "github:yaxitech/ragenix";
-      inputs = {
-        nixpkgs.follows = "nixpkgs";
-        agenix.follows = "agenix";
-        flake-utils.follows = "flake-utils";
-        rust-overlay.follows = "rust-overlay";
-        crane.follows = "crane";
-      };
-    };
     impermanence = {
       url = "github:nix-community/impermanence";
       inputs = {
@@ -224,15 +212,6 @@
     };
 
     # my bins
-    shell_library = {
-      url = "git+https://codeberg.org/soispha/shell_library.git";
-      inputs = {
-        nixpkgs.follows = "nixpkgs";
-        flake-utils.follows = "flake-utils";
-        systems.follows = "systems";
-        flake_version_update.follows = "flake_version_update";
-      };
-    };
     qmk_firmware = {
       url = "git+https://git.foss-syndicate.org/bpeetz/qmk_layout.git?ref=prime";
       inputs = {
@@ -257,81 +236,85 @@
     self,
     nixpkgs,
     nixpkgs-stable,
-    nixpkgs-lf,
     library,
     # modules
     home-manager,
     nixos-generators,
     impermanence,
     agenix,
-    ragenix,
     serverphone,
     disko,
     lanzaboote,
-    nixVim,
+    nixvim,
     nix-index-database,
     arkenfox-nixos,
     # external dependencies
     treefmt-nix,
     templates,
     # my binaries
-    shell_library,
     qmk_firmware,
     ...
   }: let
     system = "x86_64-linux";
-    sysLib = shell_library.lib.${system};
 
-    baseLib = import ./lib {inherit (pkgs) lib;};
+    packageSets = rec {
+      stable = nixpkgs-stable.legacyPackages.${system};
+      unstable = nixpkgs.legacyPackages.${system};
 
-    inherit (library) nixLib;
-
-    pkgsStable = nixpkgs-stable.legacyPackages.${system};
-    pkgs = nixpkgs.legacyPackages.${system};
-    myPkgs = import ./pkgs {
-      inherit sysLib pkgs nixLib;
+      soispha = import ./pkgs {
+        inherit libraries;
+        pkgs = unstable;
+      };
     };
 
-    nixpkgs_as_input = nixpkgs;
-    nixpkgs_open_prs = {
-      inherit
-        nixpkgs-lf
-        ;
+    libraries = rec {
+      nix = packageSets.unstable.lib;
+      base = import ./lib {lib = nix;};
+      extra = library.nixLib;
     };
 
-    outputs = import ./flake {
+    modules = {
       inherit
-        # core
-        self
-        pkgs
-        pkgsStable
-        nixLib
-        myPkgs
-        system
-        sysLib
-        baseLib
-        nixpkgs_as_input
-        nixpkgs_open_prs
-        # modules
         home-manager
-        nixVim
+        nixvim
         nixos-generators
         impermanence
         agenix
-        ragenix
         serverphone
         disko
         lanzaboote
         nix-index-database
         arkenfox-nixos
-        # external dependencies
+        ;
+    };
+
+    externalDependencies = {
+      inherit
         treefmt-nix
         templates
-        # my binaries
-        shell_library
+        ;
+    };
+
+    externalBinaries = {
+      inherit
         qmk_firmware
         ;
     };
+
+    openPRsNixpkgs = {};
+
+    outputs = import ./flake {
+      inherit
+        self
+        system
+        openPRsNixpkgs
+        packageSets
+        libraries
+        modules
+        externalDependencies
+        externalBinaries
+        ;
+    };
   in
     outputs;
 }