Last active
March 1, 2021 22:44
-
-
Save danieltomasz/462c92bbc6629581ae6eed473d28c33e to your computer and use it in GitHub Desktop.
dotfiles
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git init --bare $HOME/.dotfiles | |
alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME' | |
dotfiles config --local status.showUntrackedFiles no | |
echo "alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'" >> $HOME/.bashrc | |
dotfiles status | |
dotfiles add .bashrc | |
dotfiles add .i3/config | |
dotfiles add .config/i3 | |
dotfiles add .config/termite | |
dotfiles add .mne/mne-python.json | |
dotfiles add Obrazy/Wallpapers/005.png | |
dotfiles add ~/.config/i3status/config | |
dotfiles commit -m ' meaningful commit ...' | |
git remote add upstream https://github.com/danieltomasz/dotfiles.git | |
git add -u # add modified files | |
git --git-dir=$HOME/.dotfiles/ push -u origin master | |
#clone to different computer | |
echo "alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'" >> $HOME/.bashrc | |
echo ".dotfiles" >> .gitignore | |
git clone --bare https://github.com/danieltomasz/dotfiles.git $HOME/.dotfiles | |
mkdir -p .dotfiles-backup && dotfiles checkout 2>&1 | egrep "\s+\." | awk {'print $1'} | xargs -I{} mv {} .dotfiles-backup/{} | |
dotfiles checkout | |
dotfiles config --local status.showUntrackedFiles no | |
dotfiles add ... | |
[source](https://developer.atlassian.com/blog/2016/02/best-way-to-store-dotfiles-git-bare-repo/) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment