Skip to content
Commit 75745f00 authored by Andrew Bayer's avatar Andrew Bayer Committed by Oleg Nenashev
Browse files

[FIXED JENKINS-37731] Change symbol and constructor for SCMTrigger. (#2526)

* [FIXED JENKINS-37731] Change symbol and constructor for SCMTrigger.

Using "scm" as the @Symbol led to collisions with the "scm" global
variable in Pipeline, so that had to go. Changed it to "pollScm". Also
moved the @DataBoundConstructor to the single-parameter constructor,
deprecated the two-parameter constructor, created a @DataBoundSetter
for ignorePostCommitHooks, and added a getter for "scmpoll_spec" to
fix snippet generator and general syntactic goodness.

So now, with this, it's possible to do:

properties([
  pipelineTriggers([
    pollScm('@daily')
  ])
])

Tada.

Tests for the snippet generator and job property stuff will be landing
in a separate PR for workflow-multibranch.

* Review comments.

* Updating @since to 2.22
parent 5d3b23da
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment