Skip to content

Instantly share code, notes, and snippets.

@boechat107
Last active May 9, 2016 09:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save boechat107/3985d014b4ea5bdcb7a523c35b836631 to your computer and use it in GitHub Desktop.
Save boechat107/3985d014b4ea5bdcb7a523c35b836631 to your computer and use it in GitHub Desktop.
Useful git commands to remember

Interactive rebase of a branch. Among many options and actions, it allows the removal of specific commits. Useful for release branches or to submit PRs.

git rebase -i SHA-OF-FIRST-COMMIT-IN-BRANCH

Command to fetch a remote branch, creating a local branch with a different name (reference).

git fetch <remote> <rbranch>:<lbranch>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment