Prerequisite
Setup
Create a repo in your $HOME.
cd ~
git initCreate a .gitignore file with the following contents:
*This makes all files and directories in the git repo ignored by default.
Usage
Adding Files
To add a file, force git to bypass the .gitignore file:
git add -f ~/.zshrcRemoving Files
To remove a file, simply make git forget about it.
git rm ~/.zshrcDeploy on a New Machine
In your $HOME, add your dotfiles repo as a remote origin. Then pull all files to your computer.
cd ~
git remote add origin git@github.com:bluedragon1221/dotfiles
git pull