📝 Josh's Notes

Backing up dotfiles with chezmoi

On Bluefin, chezmoi is installed by default. But it can be installed using brew

brew install chezmoi

BEFORE YOU BEGIN: Before getting started, create a github repo called dotfiles

  1. Initialize chezmoi
chezmoi init
  1. Add a dotfile that you want to manage with chezmoi
chezmoi add ~/.bashrc
  1. When editing the file, use chezmoi
chezmoi edit ~/.bashrc
  1. Apply changes
1chezmoi -v apply

NOTE: you can view differences with chezmoi diff

chezmoi cd
git add .
git commit -m "Initial commit"
git remote add origin [email protected]:$GITHUB_USERNAME/dotfiles.git
git branch -M main
git push -u origin main

#dotfiles #chezmoi #github