Github pages blog
Delete already merged branches except master:
git branch --merged | grep -Ev "(^\*|^\+|master|main|dev)" | xargs --no-run-if-empty git branch -d
Prunes branches your local git is aware of:
git remote prune origin
Create branch off another branch:
git checkout -b my-feature-branch master
Pull changes to submodule after cloning:
git clone git://github.com/foo/bar.git
cd bar
git submodule update --init --recursive
Pull new changes from submodule/s
git submodule update --remote --merge
Fix merge conflict in submodule:
Basically:
git checkout master submodule-dir/
Fetch repo and all branches