From 133fa31b2662d3d43db31df67196ecd7d33bdcf2 Mon Sep 17 00:00:00 2001 From: Charlie Root Date: Tue, 29 Oct 2024 17:27:04 +0100 Subject: [PATCH] nix/module.nix: switch to lix module from nixpkgs Avoid builing lix every update this way. --- flake.lock | 90 +++++++++++++++++++++++++++++++++-- flake.nix | 6 +++ modules/system/nix/module.nix | 2 + 3 files changed, 95 insertions(+), 3 deletions(-) diff --git a/flake.lock b/flake.lock index de0e2f8..047ef5f 100644 --- a/flake.lock +++ b/flake.lock @@ -269,6 +269,39 @@ "type": "github" } }, + "flake-utils_4": { + "inputs": { + "systems": "systems_5" + }, + "locked": { + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "flakey-profile": { + "locked": { + "lastModified": 1712898590, + "narHash": "sha256-FhGIEU93VHAChKEXx905TSiPZKga69bWl1VB37FK//I=", + "owner": "lf-", + "repo": "flakey-profile", + "rev": "243c903fd8eadc0f63d205665a92d4df91d42d9d", + "type": "github" + }, + "original": { + "owner": "lf-", + "repo": "flakey-profile", + "type": "github" + } + }, "gitignore": { "inputs": { "nixpkgs": [ @@ -605,6 +638,41 @@ "type": "github" } }, + "lix": { + "flake": false, + "locked": { + "lastModified": 1723503926, + "narHash": "sha256-Rosl9iA9MybF5Bud4BTAQ9adbY81aGmPfV8dDBGl34s=", + "rev": "bcaeb6388b8916ac6d1736e3aa2b13313e6a6bd2", + "type": "tarball", + "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/bcaeb6388b8916ac6d1736e3aa2b13313e6a6bd2.tar.gz?rev=bcaeb6388b8916ac6d1736e3aa2b13313e6a6bd2" + }, + "original": { + "type": "tarball", + "url": "https://git.lix.systems/lix-project/lix/archive/2.91.0.tar.gz" + } + }, + "lix-module": { + "inputs": { + "flake-utils": "flake-utils_3", + "flakey-profile": "flakey-profile", + "lix": "lix", + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1723510904, + "narHash": "sha256-zNW/rqNJwhq2lYmQf19wJerRuNimjhxHKmzrWWFJYts=", + "rev": "622a2253a071a1fb97a4d3c8103a91114acc1140", + "type": "tarball", + "url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/622a2253a071a1fb97a4d3c8103a91114acc1140.tar.gz?rev=622a2253a071a1fb97a4d3c8103a91114acc1140" + }, + "original": { + "type": "tarball", + "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.91.0.tar.gz" + } + }, "mnw": { "locked": { "lastModified": 1726188505, @@ -645,7 +713,7 @@ "neovim-flake": { "inputs": { "flake-parts": "flake-parts_2", - "flake-utils": "flake-utils_3", + "flake-utils": "flake-utils_4", "mnw": "mnw", "nil": "nil", "nixpkgs": [ @@ -754,7 +822,7 @@ "plugin-vim-vsnip": "plugin-vim-vsnip", "plugin-which-key": "plugin-which-key", "rnix-lsp": "rnix-lsp", - "systems": "systems_5" + "systems": "systems_6" }, "locked": { "lastModified": 1728378979, @@ -2730,6 +2798,7 @@ "hyprland-plugins": "hyprland-plugins", "hyprsplit": "hyprsplit", "impermanence": "impermanence", + "lix-module": "lix-module", "neovim-flake": "neovim-flake", "nixpkgs": "nixpkgs_4", "nixpkgs-stable": "nixpkgs-stable_3", @@ -2799,7 +2868,7 @@ "nixpkgs" ], "searx-randomizer": "searx-randomizer", - "systems": "systems_6" + "systems": "systems_7" }, "locked": { "lastModified": 1730097974, @@ -2956,6 +3025,21 @@ } }, "systems_6": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "systems_7": { "locked": { "lastModified": 1689347949, "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", diff --git a/flake.nix b/flake.nix index 3dd363f..6abd150 100644 --- a/flake.nix +++ b/flake.nix @@ -17,6 +17,12 @@ nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-24.05"; + # Lix, a faster nix fork. + lix-module = { + url = "https://git.lix.systems/lix-project/nixos-module/archive/2.91.0.tar.gz"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + home-manager = { url = "github:nix-community/home-manager"; inputs.nixpkgs.follows = "nixpkgs"; diff --git a/modules/system/nix/module.nix b/modules/system/nix/module.nix index 4ab8328..95176d1 100644 --- a/modules/system/nix/module.nix +++ b/modules/system/nix/module.nix @@ -11,6 +11,8 @@ in { imports = [ ./documentation.nix # nixos documentation ./nixpkgs.nix # global nixpkgs configuration + + inputs.lix-module.nixosModules.lixFromNixpkgs ]; nix = {