- Boot NixOS installer and follow instructions up to but excluding nixos-generate-config
mkdir -p /mnt/etc/nixos
git clone https://github.com/strangeglyph/nix-home /mnt/etc/nixos/nixos.d
bash /mnt/etc/nixos/nixos.d/setup-config.sh -r /mnt -h <hostname>
- Edit
/mnt/etc/nixos/nixos.d/config/<hostname>.nix
to your liking, if it doesn't exist yet. See e.g.aeolus.nix
oreuclid.nix
. In particular, set or updatesystem.stateVersion
. nixos-install
nixos-enter
,passwd <normal user>
- Reboot and veryify installation
- Log in as the user you want to set up HomeManager for
bash /etc/nixos/nixos.d/setup-home
- Edit
~/nix-home/home/<hostname>/default.nix
and~/nix-home/home/<hostname>/<user>.nix
, if they don't exist. In particular, set or updatehome.stateVersion
in<user>.nix
. nix-channel --add https://github.com/nix-community/home-manager/archive/release-<stateVersion>.tar.gz home-manager
nix-channel --update
- reboot
nix-shell '<home-manager>' -A install
- Done! (May need to log in again)