The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

tools/dev/merge_pull_request.pl - Merge Github Pull Requests

SYNOPSIS

The typical workflow to merge a pull request into parrot.git

  # merge pull request #123 into current branch
  perl tools/dev/merge_pull_request.pl 123
  # this creates the branch pull_request_123
  make test # etc...

DESCRIPTION

This script implements Parrot's merge of github pull requests.

SQUASHING COMMITS

If the pull request has lots of extraneous commits, you may want to "squash" them into one commit. If you want to squash the last five commits:

  git rebase -i HEAD~5

This will open up your editor. Follow the instructions for squashing commits together.

  # If the pull request is ready to be merged to master
  git checkout master
  git merge --no-ff pull_request_123
  git push
  git branch -d pull_request_123

  # If working copy changed were stashed (the script will notify you)
  # pop those back off the stash
  git stash pop

This script can be used to merge a pull request for any repo in the Parrot Github Organization. For instance, to merge Cardinal Pull request #4:

 perl $PARROT/tools/dev/merge_pull_request.pl 4 cardinal

If you do not want the default branch name, you can specify a third argument to specify one:

 perl $PARROT/tools/dev/merge_pull_request.pl 4 cardinal awesome_feature

This will merge pull request #4 in the cardinal repo into a branch called 'awesome_feature'.