Under the project folder
- git init
- git add -A .
- git commit -m "first commit"
- git remote add origin %remote_repository_url%
- git push origin master
- git fetch origin
- git reset --hard origin/master
- git branch newbranch
- git checkout newbranch
- one liner: git checkout -b newbranch
- git push --set-upstream origin newbranch
- local
- git branch -d newbranch
- remote
- git push <remote_name> --delete newbranch
- git ls-remote (to get the commit id)
- git revert --no-edit %commit-number%