Skip to content

Instantly share code, notes, and snippets.

@leimingyu
Last active October 17, 2023 12:46
Show Gist options
  • Save leimingyu/2d09b2d27bde19c6f57d643cc271c07a to your computer and use it in GitHub Desktop.
Save leimingyu/2d09b2d27bde19c6f57d643cc271c07a to your computer and use it in GitHub Desktop.
git command cheatsheet
  • create a new branch
git checkout -b <new branch name>
  • list all branches
git branch -a
  • push local branch to remote
git push --set-upstream origin <yourNewLocalBranch>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment