HowTo GIT for me, myself and I...
git branch -a
-> list all branchesgit push -u origin BRANCHNAME
-> push new branch remotely/upstreamgit checkout BRANCHNAME/HASH
-> switch to branchgit checkout <HASH> -- file.c
-> checkout a specific version of a file.cgit merge BRANCHNAME/HASH
-> automatic mergegit mergetool
-> merge manuallygit submodule add <URL> <SUBDIR>
git submodule update --init --recursive
git -c submodule.UnitTestFrameworkPkg/Library/SubhookLib/subhook.update=none submodule update --init --recursive
-> skip broken submodule UnitTestFrameworkPkg/Library/SubhookLib/subhookgit reset --hard
-> last commited state of entire repositorygit reset <PATH\FILE>
-> unstage a particular filegit log --simplify-by-decoration
-> list branches and tags onlygit fetch
git pull
git checkout --patch BRANCHNAME file
-> merge a single file from a different branchgit tag <tag_name>
set tag_namegit tag -a <tag_name> -m "message"
git tag
list tagsgit push --tags
git submodule deinit SUBDIR
git rm --cached SUBDIR
rd /s /q .git\modules\SUBDIR
rd /s /q SUBDIR
git submodule add <URL> SUBDIR
git remote -v
-> list remotesgit remote rm origin
-> delete origingit remote add origin <remote URL>
-> assign new origingit pull --allow-unrelated-hisories
git push origin HEAD:master