Git Cheatsheet
-
git mv old/submod new/submod
- move a submodule -
git rm <path to submodule> && git commit -m "remove submodule"
- remove a submodule (Yes, it got a lot easier with modern versions of git. See this StackOverflow answer.) -
git rebase -i HEAD~3
- rebase the last 3 commits -
git rebase -i --root
- rebase the entire history of a repository -
git init <project name>
- start a new git repository