This document provides context for AI agents working with this NixOS configuration repository.
This is a NixOS configuration project using Nix Flakes. It manages the system state and user environments for multiple machines (hosts) declaratively.
- Primary User:
kita - Platform: x86_64-linux
- Hosts:
desktop: Performance-oriented configuration (AMD + NVIDIA).laptop: Power-optimized configuration (Intel-only RedmiBook Pro 15).
flake.nix: The entry point. Defines inputs and outputs.hosts/: Host-specific entry points and hardware scan results.system/: System-wide NixOS modules.system/common/: Shared system logic (core, hardware, apps, stylix). Optimized for modularity with consolidateddefault.nixentry points.
home/: Home Manager configurations.home/common/: Shared user applications and dotfiles (core, dev, gui, shells, terminals).home/desktop/: GUI-related user configuration (Hyprland, Niri, waybar, rofi).
pkgs/: Custom packages.wallpapers/: System wallpapers.
sudo nixos-rebuild switch --flake .#<hostname>- Garbage Collection:
sudo nh cleanornix-collect-garbage -d - Update Inputs:
nix flake update - Format Code:
alejandra .
- Hardware: CPU, GPU, and Device type (Laptop/Desktop) are decoupled into
system/hardware/. - Imports: Host configurations should import from
system/hardware/to match their physical components. - Modularity: Configurations are grouped by category into subdirectories with
default.nixas the entry point. Small related files are consolidated intodefault.nixto minimize directory clutter.
- WindowManagers: Hyprland and Niri (configured in
home/desktop/). - Theming:
stylixfor global theming (Gruvbox dark). - Development: Nixvim (fully synced local config), VSCodium.
- Power Management:
tlpandpowertopfor laptops. - Virtualization: Podman and Libvirt/QEMU.