.files for my own personal use.
- Create a setup script to run all of the commands in the "Start from a fresh machine" -section automatically?
- Install NixOS on a machine or VM.
- Create an SSH key for GitHub using:
ssh-keygen -t ed25519
, and add it to the SSH agent using:ssh-add ~/.ssh/id_ed25519
- Upload the public SSH key to GitHub (you may need to do:
eval
ssh-agent -s`` to set up env for ssh-add) - Temporarily add git to NixOS using:
nix-env --install git
- Clone the repo to a temp. folder using:
git clone [email protected]:JonasPhilbert/dotfiles.git ~/dotfiles
- Copy repo contents to home using:
cp ~/dotfiles/. ~ -rf
- Delete temporary folder using:
rm -rf ~/dotfiles
- Copy NixOS hardware configuration to main NixOS flake folder using:
sudo cp /etc/nixos/hardware-configuration.nix ~/.nixos
- Temporarily add the hardware config to git to allow a nix build using:
git add -f ~/.nixos/hardware-configuration.nix
- Rebuild NixOS using the cloned flake using:
sudo nixos-rebuild switch --flake ~/.nixos#nixos
- Profit! 🎉
- Configure in the future using the custom fish command:
nixosconf
TODO