My little automation for setting up my environment.
Everything is managed by a Nix Home Manager
flake. Home Manager owns every dotfile: each config is an out-of-store symlink from ~
(or ~/.config) into this repo, so files stay editable in place and edits are picked up
live — no copy into the Nix store, and no GNU Stow.
This repo previously used GNU Stow for the dotfiles while keeping Home Manager for packages. It has since migrated back to pure Home Manager — see
STOW-TO-HOME-MANAGER-MIGRATION.md.
flake.nix/flake.lock— the Home Manager flake (per-hosthomeConfigurations).home/— the Home Manager modules (home.nix,packages.nix, …) plushome/files.nix, which imports every dotfile as an out-of-store symlink.home/hosts/<host>/— per-host config.lib/dotfiles.nix— the import helper (dot-foo→.foo, like Stow's--dotfiles).config/→~/.config,home-files/→~/,home-bin/→~/.local/bin,themes/→~/.themes,icons/→~/.icons.
curl -L https://codeberg.org/CourteousCoder/dotfiles/raw/branch/main/bootstrap.sh | sh -sFirst:
SOURCE="git@codeberg.org:CourteousCoder/dotfiles.git"
DEST="$HOME/.dotfiles"
git clone "$SOURCE" "$DEST"
"$PAGER" "$DEST/bootstrap.sh"Then inspect the script before you run it:
"$DEST/bootstrap.sh"bootstrap.sh installs Nix, then runs just setup_dotfiles, which installs the gitleaks
pre-commit hook and activates Home Manager.
just switch— activate (nh home switch ~/.dotfiles).just build— build without activating.just update— update flake inputs and switch (runsnixup).
This is just a fun little tinkering project for myself. There are probably way better ways of handling this, and that's okay with me.
If you really want to contribute or share your opinion, go ahead and create an issue. I always welcome opportunities to improve!