Added support for applying GitHub pull requests.

Review: https://reviews.apache.org/r/20173