aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorReno Reckling <reno.reckling@mayflower.de>2014-07-24 12:37:17 +0200
committerReno Reckling <reno.reckling@mayflower.de>2014-07-24 12:37:17 +0200
commit5a4727ed6304aba33ab9f9115f961c02d860da39 (patch)
tree5e20a486dd2e7ce50a9fe70f5992e15d5a0a0afb /src/main
parente45ff6c1f31b57be787326f8b5ecd41ab988a1be (diff)
downloadbbprb-5a4727ed6304aba33ab9f9115f961c02d860da39.tar.gz
explicitly specify git hash to build
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/bitbucketpullrequestbuilder/bitbucketpullrequestbuilder/BitbucketBuildTrigger.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/bitbucketpullrequestbuilder/bitbucketpullrequestbuilder/BitbucketBuildTrigger.java b/src/main/java/bitbucketpullrequestbuilder/bitbucketpullrequestbuilder/BitbucketBuildTrigger.java
index 65777a3..af4e98c 100644
--- a/src/main/java/bitbucketpullrequestbuilder/bitbucketpullrequestbuilder/BitbucketBuildTrigger.java
+++ b/src/main/java/bitbucketpullrequestbuilder/bitbucketpullrequestbuilder/BitbucketBuildTrigger.java
@@ -4,6 +4,7 @@ import antlr.ANTLRException;
import hudson.Extension;
import hudson.model.*;
import hudson.model.queue.QueueTaskFuture;
+import hudson.plugins.git.RevisionParameterAction;
import hudson.triggers.Trigger;
import hudson.triggers.TriggerDescriptor;
import net.sf.json.JSONObject;
@@ -113,7 +114,7 @@ public class BitbucketBuildTrigger extends Trigger<AbstractProject<?, ?>> {
values.put("destinationRepositoryOwner", new StringParameterValue("destinationRepositoryOwner", cause.getDestinationRepositoryOwner()));
values.put("destinationRepositoryName", new StringParameterValue("destinationRepositoryName", cause.getDestinationRepositoryName()));
values.put("pullRequestTitle", new StringParameterValue("pullRequestTitle", cause.getPullRequestTitle()));
- return this.job.scheduleBuild2(0, cause, new ParametersAction(new ArrayList(values.values())));
+ return this.job.scheduleBuild2(0, cause, new ParametersAction(new ArrayList(values.values())), new RevisionParameterAction(cause.getCommitHash()));
}
private Map<String, ParameterValue> getDefaultParameters() {