flake.nix: working multi-system config
This commit is contained in:
parent
1035c45548
commit
265c5bbc40
1 changed files with 10 additions and 0 deletions
10
flake.nix
10
flake.nix
|
@ -2,6 +2,7 @@
|
|||
description = "My NixOS config flake";
|
||||
outputs = inputs: let
|
||||
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
|
||||
user = import ./modules/user {inherit pkgs;};
|
||||
eachSystem = inputs.nixpkgs.lib.genAttrs (import inputs.systems);
|
||||
pkgsFor = inputs.nixpkgs.legacyPackages;
|
||||
in {
|
||||
|
@ -10,12 +11,20 @@
|
|||
devShells.x86_64-linux.default = pkgs.callPackage ./shell.nix {};
|
||||
|
||||
formatter.x86_64-linux = pkgs.alejandra;
|
||||
# packages.x86_64-linux = {inherit (user) packages;};
|
||||
|
||||
packages = eachSystem (
|
||||
system: {
|
||||
inherit (import ./packages pkgsFor.${system}) helix fish;
|
||||
}
|
||||
);
|
||||
# packages = eachSystem (
|
||||
# system: let
|
||||
# user = import ./modules/user {pkgs = pkgsFor.${system};};
|
||||
# in {
|
||||
# inherit (user) packages;
|
||||
# }
|
||||
# );
|
||||
|
||||
apps = eachSystem (system: let
|
||||
user = import ./modules/user {pkgs = pkgsFor.${system};};
|
||||
|
@ -34,6 +43,7 @@
|
|||
# in {
|
||||
# user = user.module;
|
||||
# });
|
||||
# nixosModules.user = user.module;
|
||||
};
|
||||
inputs = {
|
||||
# Unstable nixpkgs baby!
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue