memowe / dotfiles

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dotfiles handling

Read the whole blog post: Nicola Paolucci: The best way to store your dotfiles: A bare Git repository

$ git clone --recurse-submodules -j8 --bare https://github.com/memowe/dotfiles.git $HOME/.dotfiles.git

.bashrc file:

alias dotfiles='/usr/bin/env git --git-dir=$HOME/.dotfiles.git --work-tree=$HOME'

and

$ dotfiles submodule update --init --recursive
$ cd .vim && make && cd -

Show added files only:

$ dotfiles config --local status.showUntrackedFiles no

Sometimes, this needs to be done to make dotfiles fetch --all work as expected.

$ dotfiles config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*"

The dotfiles command works now exactly like git does:

$ dotfiles status
$ dotfiles checkout work .tmux.conf
$ dotfiles add .config/redshift.conf
$ dotfiles commit -m 'Add redshift config'
$ dotfiles push origin work

About


Languages

Language:Shell 100.0%