code review
This commit is contained in:
Generated
+17
-1
@@ -899,6 +899,7 @@
|
|||||||
"nixvim": "nixvim",
|
"nixvim": "nixvim",
|
||||||
"nvchad-starter": "nvchad-starter",
|
"nvchad-starter": "nvchad-starter",
|
||||||
"nvchad4nix": "nvchad4nix",
|
"nvchad4nix": "nvchad4nix",
|
||||||
|
"systems": "systems_3",
|
||||||
"utils": "utils"
|
"utils": "utils"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -933,6 +934,21 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"systems_3": {
|
"systems_3": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1689347949,
|
||||||
|
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default-linux",
|
||||||
|
"rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default-linux",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"systems_4": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681028828,
|
"lastModified": 1681028828,
|
||||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
@@ -970,7 +986,7 @@
|
|||||||
},
|
},
|
||||||
"utils": {
|
"utils": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_3"
|
"systems": "systems_4"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1726560853,
|
"lastModified": 1726560853,
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
|
systems.url = "github:nix-systems/default-linux";
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
@@ -32,61 +33,48 @@
|
|||||||
utils.url = "github:numtide/flake-utils";
|
utils.url = "github:numtide/flake-utils";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs =
|
outputs = { self, systems, nixpkgs, home-manager, utils, catppuccin, foundry
|
||||||
{ self, nixpkgs, home-manager, utils, catppuccin, foundry, ... }@inputs:
|
, ... }@inputs:
|
||||||
utils.lib.eachDefaultSystem (system:
|
let
|
||||||
let
|
inherit (self) outputs;
|
||||||
inherit (self) outputs;
|
pkgsFor = nixpkgs.lib.genAttrs (import systems) (system:
|
||||||
x86 = nixpkgs.legacyPackages.x86_64-linux;
|
import nixpkgs {
|
||||||
forEachSystem = nixpkgs.lib.genAttrs [ "x86_64-linux" ];
|
inherit system;
|
||||||
forEachPkg = f: forEachSystem (sys: f nixpkgs.legacyPackages.${sys});
|
config.allowUnfree = true;
|
||||||
pkgs = import nixpkgs {
|
});
|
||||||
inherit x86;
|
x86 = nixpkgs.legacyPackages.x86_64-linux;
|
||||||
overlays = [ foundry.overlay ];
|
forEachSystem = nixpkgs.lib.genAttrs [ "x86_64-linux" ];
|
||||||
};
|
forEachPkg = f: forEachSystem (sys: f nixpkgs.legacyPackages.${sys});
|
||||||
mkNixOS = extraModules:
|
mkNixOS = extraModules:
|
||||||
nixpkgs.lib.nixosSystem {
|
nixpkgs.lib.nixosSystem {
|
||||||
inherit extraModules;
|
inherit extraModules;
|
||||||
specialArgs = { inherit inputs outputs; };
|
modules = extraModules ++ [ catppuccin.nixosModules.catppuccin ];
|
||||||
modules = extraModules ++ [
|
specialArgs = { inherit inputs outputs; };
|
||||||
catppuccin.nixosModules.catppuccin
|
|
||||||
{
|
|
||||||
nixpkgs = {
|
|
||||||
overlays = [
|
|
||||||
foundry.overlay
|
|
||||||
(final: prev: {
|
|
||||||
nvchad =
|
|
||||||
inputs.nvchad4nix.packages."${pkgs.system}".nvchad;
|
|
||||||
})
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
mkHome = modules: pkgs:
|
|
||||||
home-manager.lib.homeManagerConfiguration {
|
|
||||||
inherit modules pkgs;
|
|
||||||
extraSpecialArgs = { inherit inputs outputs catppuccin; };
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
nixosConfigurations = {
|
|
||||||
laptop = mkNixOS [ ./hosts/laptop ];
|
|
||||||
arrakis = mkNixOS [ ./hosts/arrakis ];
|
|
||||||
desktop = mkNixOS [ ./hosts/desktop ];
|
|
||||||
test = mkNixOS [ ./hosts/test ];
|
|
||||||
pi = mkNixOS [ ./hosts/pi ];
|
|
||||||
live = mkNixOS [ ./hosts/live ];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
homeConfigurations = {
|
mkHome = modules: pkgs:
|
||||||
"naps62@laptop" = mkHome [ ./home-manager/laptop ] x86;
|
home-manager.lib.homeManagerConfiguration {
|
||||||
"naps62@arrakis" = mkHome [ ./home-manager/arrakis ] x86;
|
inherit modules pkgs;
|
||||||
"naps62@desktop" = mkHome [ ./home-manager/desktop ] x86;
|
extraSpecialArgs = { inherit inputs outputs catppuccin; };
|
||||||
"naps62@pi" = mkHome [ ./home-manager/pi ] x86;
|
|
||||||
"naps62@test" = mkHome [ ./home-manager/test ] x86;
|
|
||||||
};
|
};
|
||||||
|
in {
|
||||||
|
nixosConfigurations = {
|
||||||
|
laptop = mkNixOS [ ./hosts/laptop ];
|
||||||
|
arrakis = mkNixOS [ ./hosts/arrakis ];
|
||||||
|
desktop = mkNixOS [ ./hosts/desktop ];
|
||||||
|
test = mkNixOS [ ./hosts/test ];
|
||||||
|
pi = mkNixOS [ ./hosts/pi ];
|
||||||
|
live = mkNixOS [ ./hosts/live ];
|
||||||
|
};
|
||||||
|
|
||||||
devShells = forEachPkg (pkgs: import ./shell.nix { inherit pkgs; });
|
homeConfigurations = {
|
||||||
});
|
laptop = mkHome [ ./home-manager/laptop ] pkgsFor.x86_64-linux;
|
||||||
|
arrakis = mkHome [ ./home-manager/arrakis ] pkgsFor.x86_64-linux;
|
||||||
|
desktop = mkHome [ ./home-manager/desktop ] pkgsFor.x86_64-linux;
|
||||||
|
pi = mkHome [ ./home-manager/pi ] pkgsFor.aarch64-linux;
|
||||||
|
test = mkHome [ ./home-manager/test ] pkgsFor.x86_64-linux;
|
||||||
|
};
|
||||||
|
|
||||||
|
devShells = forEachPkg (pkgs: import ./shell.nix { inherit pkgs; });
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user