Skip to content

Instantly share code, notes, and snippets.

@asalhani
Last active July 1, 2018 06:19
Show Gist options
  • Save asalhani/ca20b793b48be2bdbe9e7179b6c235f7 to your computer and use it in GitHub Desktop.
Save asalhani/ca20b793b48be2bdbe9e7179b6c235f7 to your computer and use it in GitHub Desktop.
Git commands - Most used
  • List branches:
    git branch

  • create new branch:
    git checkout -b <NEW_BRANCH_NAME>

  • Push the branch on github:
    git push origin <NEW_BRANCH_NAME>

  • Change working branch:
    git checkout <BRANCH_NAME>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment