Tracking Pull Requests on your HIPP instance

In a prior entry, I wrote about getting your HIPP Instance at Eclipse to run GitHub Pull Requests.  One thing that is missing from that is, the ability to identify which of the jobs that ran, ran which pull request.   By default, Hudson only outputs the job number,  so if you have multiple pull requests that are being run, there isn’t an easy way to identify which job number is associated with which pull request.

With Jenkins this would be pretty easy, as the Set Build Name plugin has been updated so it can accept Jenkins variables, unfortunately the equivalent plugin in Hudson is way behind and doesn’t understand variables besides it’s own.   There is a work around though.

Install the Set Env Plugin, which allows you to inject before the build begins system environment variables.   You can then, use the Set Build Name plugin to have it use the injected environment variable.

The setup looks similar to this:

Screen Shot 2015-02-19 at 10.02.55 AM

The PULLREQUEST_NUMBER is the Build Parameter to identify which pull request should be run.  When the job now runs you’ll get the following output in your build history.

Screen Shot 2015-02-19 at 10.04.12 AM

The job number and the Pull Request Number will be displayed for easy and quick access to the results of a particular pull request.

This entry was posted in android, eclipse, release engineering and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s