37 lines
1.6 KiB
Nix
37 lines
1.6 KiB
Nix
{
|
|
description = "NixOS configuration";
|
|
|
|
inputs = { # All flake references
|
|
# Nixpkgs
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.05"; # Default stable nix packages
|
|
|
|
# Home manager
|
|
home-manager = { # User package management
|
|
url = "github:nix-community/home-manager/release-23.05";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
};
|
|
|
|
outputs = { self, nixpkgs, home-manager, ... }@inputs:
|
|
let
|
|
inherit (self) outputs;
|
|
lib = nixpkgs.lib // home-manager.lib;
|
|
in
|
|
{
|
|
inherit lib;
|
|
nixosConfigurations = { # NixOS Configuration
|
|
"stefan@merkur" = lib.nixosSystem { # Flake "stefan@merkur" (Notebook)
|
|
specialArgs = { inherit inputs; }; # Pass flake inputs to our config
|
|
modules = [
|
|
./hosts/merkur/configuration.nix # Import configuration,nix
|
|
home-manager.nixosModules.home-manager { # Home-Manager configuration (non-NixOS)
|
|
home-manager.useGlobalPkgs = true;
|
|
home-manager.useUserPackages = true;
|
|
home-manager.users.stefan = import ./home/stefan-merkur/home.nix; # Import default.nix
|
|
}
|
|
];
|
|
};
|
|
};
|
|
};
|
|
}
|