- Untracked files won't show up if hidden. To audit, temporarily re-enable with
gh status --untracked-files=normal
. - Have to convert submodule paths in
.gitmodules
to relative paths.
- Create a script called
gh
and put it in your PATH,#!/usr/bin/env bash git --git-dir "$HOME/.dotfiles.git" --work-tree "$HOME" "$@"
- Optionally, setup Bash completion,
complete -o bashdefault -o default -o nospace -F __git_wrap__git_main gh
- Initialize your home directory,
gh init
- Hide untracked files by default,
gh config status.showUntrackedFiles no
- Then continue to either If creating your initial repo or If setting up an existing repo.
- First do Setup.
- Add files,
gh add $HOME/foo
- Commit changes,
gh commit -v
- Add remote,
gh remote add -f origin git@github.com:foo/bar.git
- Push changes,
gh push -u origin master
- First do Setup.
- Add the remote,
gh remote add -f origin git@github.com:foo/bar.git
- Checkout
master
,gh checkout master
- If conflicts, review and then force checkout
master
,gh checkout -f master