These are my dotfiles.
Clone the repo to /Users/<username>/Projects/ops/dotfiles, the path that my.host.dotfiles in nix/host.nix names.
home-manager links the config trees out of that checkout.
Each stage script checks that the Mac is ready for it.
When the Mac is not ready, the script prints what is missing and stops, so you fix that and run it again.
- Install the Xcode Command Line Tools, which include git:
xcode-select --install - Clone the repo over HTTPS and enter it:
git clone https://github.com/oschrenk/dotfiles.git ~/Projects/ops/dotfiles && cd ~/Projects/ops/dotfiles - Name the Mac and install Nix, Homebrew and 1Password:
./scripts/stage-01-install.sh - Run the first switch after the preparation below:
./scripts/stage-02-switch.sh- In 1Password, sign in and let it sync. Then enable Settings > Developer > "Use the SSH agent" and "Integrate with 1Password CLI".
- In System Settings > Privacy & Security > Full Disk Access, enable Terminal. Then quit Terminal and open it again.
- The first switch downloads and builds everything, which takes about an hour.
- If the switch stops at
universalaccessand the shell no longer opens, set Terminal > Settings > General > "Shells open with" to/bin/zsh. Then grant Full Disk Access and run the script again.
- In a new terminal, fetch the LFS files and the infuse data:
./scripts/stage-03-finish.sh
Then set up the apps by hand, with the checklist in docs/first-run.md.
Later changes apply with task nix:switch:local.
Setup all git projects
- requires ssh key (via 1Password)
- requires
arbol
mkdir ~/Projects
arbol sync
task brewInstall the taps, brews and appstask cargoInstall the cratestask customize:extensionsInstall the Arc Browser extensionstask goInstall the go appstask iconsInstall the iconstask nodeInstall the node toolstask ollamaInstall the ollama models
Nix ignores the binary caches in a flake's nixConfig unless the invoking user is a trusted user and accept-flake-config is on.
The fix is to add the cache directly to /etc/nix/nix.custom.conf (which Determinate Nix preserves across upgrades) and restart the daemon:
echo 'extra-substituters = https://example.cachix.org' | sudo tee -a /etc/nix/nix.custom.conf
echo 'extra-trusted-public-keys = example.cachix.org-1:...' | sudo tee -a /etc/nix/nix.custom.conf
sudo launchctl kickstart -k system/systems.determinate.nix-daemon