nixos-config/flake.nix

67 lines
1.8 KiB
Nix
Raw Normal View History

2022-01-06 21:14:02 -05:00
{
description = "System conf";
2022-01-06 21:14:02 -05:00
inputs = rec {
nixpkgs.url = "nixpkgs/nixos-unstable";
nur.url = "github:nix-community/NUR";
2022-03-04 13:25:16 -05:00
nixos-hardware.url = "github:NixOS/nixos-hardware";
2022-01-06 21:14:02 -05:00
home-manager.url = "github:nix-community/home-manager/master";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
2022-04-10 16:15:13 -04:00
spacemacs.url = "github:syl20bnr/spacemacs/develop";
spacemacs.flake = false;
spacemacs-config.url = "github:kiana-S/spacemacs-config";
spacemacs-config.flake = false;
2022-01-06 21:14:02 -05:00
};
2022-01-06 21:14:02 -05:00
outputs = { self,
nixpkgs,
home-manager,
nixos-hardware,
2022-01-06 21:14:02 -05:00
...}@inputs:
let
system = "x86_64-linux";
username = "kiana";
moduleArgs = inputs // { inherit system username; };
lib = nixpkgs.lib;
in {
nixosConfigurations = {
2022-01-06 22:17:01 -05:00
"kiana-desktop" = lib.makeOverridable lib.nixosSystem {
2022-01-06 21:14:02 -05:00
inherit system;
modules = [
{ _module.args = moduleArgs; }
./desktop/config
2022-03-04 09:50:43 -05:00
./common/config
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.${username} = import ./desktop/home-manager;
home-manager.extraSpecialArgs = moduleArgs;
}
];
2022-01-06 21:14:02 -05:00
};
2022-01-06 22:16:45 -05:00
2022-01-06 22:17:01 -05:00
"kiana-laptop" = lib.makeOverridable lib.nixosSystem {
2022-01-06 22:16:45 -05:00
inherit system;
modules = [
{ _module.args = moduleArgs; }
./laptop/config
2022-03-04 09:50:43 -05:00
./common/config
home-manager.nixosModules.home-manager
nixos-hardware.nixosModules.microsoft-surface
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.${username} = import ./laptop/home-manager;
home-manager.extraSpecialArgs = moduleArgs;
}
];
2022-01-06 22:16:45 -05:00
};
2022-01-06 21:14:02 -05:00
};
};
}