My personal NixOS configuration built with NixOS Flakes and modular features.
Clone the repository:
git clone https://github.com/dityaren/nixos.git
cd ./nixosMake a copy of nixos/modules/hosts/snow in the same directory and rename it into your desired hostname,
Make changes into variables:
modules/hosts/your-host-dir/vars.nix
Change the machine-specific values:
flake.vars = {
username = "your-username";
hostname = "your-hostname";
stateVersion = "26.05";
flakeRoot = "your-nixos-config-location/"; # End with /
};Then rebuild:
sudo nixos-rebuild switch --flake your-nixos-config-location#your-hostname.
├── flake.nix
├── flake.lock
└── modules/
├── hosts/
│ └── (machine)/
│ └── vars.nix
│
└── features/
├── ...
├── ...
└── ...
