dotfiles/README.md
Mads Fagerlund 64a399597a
plain: one x86_64 target, no host branching
Drops the mbp (Asahi) target and everything that existed only to serve
two machines at once:

  - apple-silicon input, firmware/ (87M of Mac Wi-Fi/BT blobs), hosts/mbp/
  - the mkHost helper and the common-vs-host-module split, merged into one
    `pc` module
  - the osConfig.networking.hostName conditional that generated
    hypr/monitors.conf per host -- the monitor layout, workspace placement
    and panel float rule are now stated once, inline in hyprland.conf
  - the aarch64 nixbuild.net builder and the aarch64 devShell
  - Mac-only hyprland bits: the apple-spi-keyboard device block and the
    touchpad input block

hosts/pc/hardware-configuration.nix moves to the repo root: with one
machine there is no host to namespace it under. The flake output stays
named `pc` so it matches networking.hostName, which means plain
`nixos-rebuild switch --flake ~/nixos` resolves it with no #target.

eww goes too. It only ever drew a battery popup (SUPER+R), and a battery
readout on a desktop with no battery is nothing.

Also fixes the services.logind.suspendKey/hibernateKey/lidSwitch rename
that eval has been warning about; the rendered logind.conf keeps the same
three Handle*=ignore directives.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-10-10 19:34:53 +02:00

1.6 KiB

nixos

One flake, one machine: x86_64 UEFI desktop. Hyprland + greetd autologin, Zen+Tridactyl, neovim, zsh+starship.

flake.nix                    all config (the `pc` system module + the `home` module)
hardware-configuration.nix   generic x86_64 UEFI profile — mounts by label, as-is
config/                      raw configs: hypr fuzzel nvim

Set time.timeZone in the pc module. Monitors, workspace placement and keybinds live in config/hypr/hyprland.conf.

Apply

The flake output is named after the hostname, so no #target is needed:

sudo nixos-rebuild switch --flake ~/nixos
nix flake update && sudo nixos-rebuild switch --flake ~/nixos   # update

Roll back = pick an older generation at boot.

Install

No hardware generation needed — hardware-configuration.nix is generic and mounts by the labels below. Boot the NixOS ISO, sudo -i:

parted /dev/nvme0n1 -- mklabel gpt \
  mkpart ESP fat32 1MiB 512MiB set 1 esp on \
  mkpart primary 512MiB 100%
mkfs.fat -F32 -n NIXBOOT /dev/nvme0n1p1
mkfs.ext4 -L NIXROOT    /dev/nvme0n1p2
mount /dev/disk/by-label/NIXROOT /mnt && mkdir -p /mnt/boot
mount /dev/disk/by-label/NIXBOOT /mnt/boot
git clone <private-remote> /mnt/root/nixos && cd /mnt/root/nixos
nixos-install --flake .#pc && reboot

Exotic storage controller won't boot? Add its module to availableKernelModules in hardware-configuration.nix (nixos-generate-config --show-hardware-config lists it).

After first boot

passwd (ships initialPassword = "changeme"). If you land on a tty instead of Hyprland, change greetd's uwsm start hyprland → Hyprland.