jenkinsci / pipeline-github-plugin

Pipeline: GitHub
https://plugins.jenkins.io/pipeline-github/
MIT License
159 stars 73 forks source link

Pipeline trigger for Pull Request reviews #89

Closed aaronwalker closed 3 years ago

aaronwalker commented 3 years ago

This PR adds a new trigger called pullRequestReview which allows for triggering a build based on the review state of the PR.

It adds the some environment variables to the pipeline with the details of the review that triggered the build but the full review history is accessible via the the pullRequest global variable.

I have tested this pretty extensively and currently have this deployed and working in a number of Jenkins environments

@aaronjwhiteside any comments/critiques welcome.

paschdan commented 3 years ago

the incremental deployment failed for this pr, can this be fixed somehow?

[2020-09-16T10:38:16.015Z] Invalid archive retrieved from Jenkins, perhaps the plugin is not properly incrementalized?

[2020-09-16T10:38:16.113Z] Error: ZIP error: Error: Wrong commit hash in /project/scm/tag from https://ci.jenkins.io/job/Plugins/job/pipeline-github-plugin/job/PR-89/1/artifact/**/*.80da3502c8bf/*.80da3502c8bf*/*zip*/archive.zip

see https://ci.jenkins.io/blue/organizations/jenkins/Plugins%2Fpipeline-github-plugin/detail/PR-89/1/pipeline