modified config for more modularity
This commit is contained in:
31
flake.nix
31
flake.nix
@ -1,8 +1,8 @@
|
||||
{
|
||||
description = "Wyatt's nix configuration suite";
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-24.05";
|
||||
# nixpkgs-darwin.url = "github:nixos/nixpkgs/nixpkgs-24.05-darwin";
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
|
||||
nixpkgs-darwin.url = "github:nixos/nixpkgs/nixpkgs-24.05-darwin";
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager/release-24.05";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
@ -22,21 +22,18 @@
|
||||
}: let
|
||||
userName = "wyatt";
|
||||
userEmail = "wyatt@wyattjmiller.com";
|
||||
# supportedSystems = ["x86_64-linux" "aarch64-darwin"];
|
||||
# system = "aarch64-darwin"; # aarch64-darwin or x86_64-darwin
|
||||
# hostname = "sephiroth";
|
||||
# forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
|
||||
|
||||
specialArgs =
|
||||
inputs
|
||||
// {
|
||||
inherit userName userEmail;
|
||||
};
|
||||
extraSpecialArgs = {
|
||||
inherit userName userEmail;
|
||||
};
|
||||
in {
|
||||
# Primary laptop - MacBook Pro (2023, M3)
|
||||
darwinConfigurations."sephiroth" = darwin.lib.darwinSystem {
|
||||
inherit specialArgs;
|
||||
system = "aarch64-darwin";
|
||||
specialArgs = {
|
||||
inherit userName userEmail;
|
||||
hostname = "sephiroth";
|
||||
};
|
||||
# nixpkgs = inputs.nixpkgs-darwin;
|
||||
modules = [
|
||||
./modules/nix-core.nix
|
||||
./modules/darwinSystem.nix
|
||||
@ -47,7 +44,7 @@
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.extraSpecialArgs = specialArgs;
|
||||
home-manager.extraSpecialArgs = extraSpecialArgs;
|
||||
home-manager.users.${userName} = import ./home;
|
||||
}
|
||||
];
|
||||
@ -55,8 +52,11 @@
|
||||
|
||||
# Primary desktop computer
|
||||
nixosConfiguration."cloud" = nixpkgs.lib.nixosSystem {
|
||||
inherit specialArgs;
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inherit userName userEmail;
|
||||
hostname = "cloud";
|
||||
};
|
||||
modules = [
|
||||
/etc/nixos/configuration.nix
|
||||
./modules/nix-core.nix
|
||||
@ -67,6 +67,7 @@
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.extraSpecialArgs = extraSpecialArgs;
|
||||
home-manager.users.${userName} = import ./home;
|
||||
}
|
||||
];
|
||||
|
Reference in New Issue
Block a user