Skip to content

Instantly share code, notes, and snippets.

@Integralist
Last active August 29, 2015 14:05
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Integralist/43b6da80a91827671e55 to your computer and use it in GitHub Desktop.
Save Integralist/43b6da80a91827671e55 to your computer and use it in GitHub Desktop.
Process for rebasing Pull Request
  1. On the PR branch
  2. git rebase -i master (i.e. git rebase -i {parent_commit_of_first_commit_in_PR})
  3. Change top commit (the oldest) to reword
  4. Change all other commits to fixup
  5. In commit message (line 1) change title to reflect entire PR
  6. In commit message (line 2) add Closes #n and/or Fixes #n
  7. In commit message (line 3) add Authors: @integralist
  8. git checkout master
  9. git merge {PR_branch} or git cherry-pick {new_rebased_commit}
  10. git branch -D {PR_branch}
  11. git push origin master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment