Skip to end of metadata
Go to start of metadata

Plugin Information

Plugin ID script-scm Changes In Latest Release
Since Latest Release
Latest Release
Latest Release Date
Required Core
Sep 29, 2013
Source Code
Issue Tracking
Open Issues
vimil (id: vimil)
Usage Installations 2013-Apr 59
2013-May 61
2013-Jun 66
2013-Jul 71
2013-Aug 73
2013-Sep 68
2013-Oct 80
2013-Nov 70
2013-Dec 79
2014-Jan 91
2014-Feb 84
2014-Mar 83

The Script SCM plugin allows SCM polling to be managed using scripts.
The basic concept is as follows. 

The plugin allows a groovy script to be configured to manage SCM polling and checkout life cycle. The groovy script can be embedded directly on the config page of the project or a reference to an external groovy script file can be specified.
The plugin also provides the groovy script with a mechanism to invoke an external ant script. The idea is that the groovy script has access to the Jenkins API but not to the SCM. The ant script has access to the SCM but not to the jenkins API. The groovy script together with an ant script provides the communication link between the Jenkins API and the SCM. 

Whenever Jenkins polls the script-scm plugin for changes, the plugin invokes the groovy script passing in a variable called 'action' with the value 'compareWithRemoteVersion'.
The groovy script can then check the value of the 'action' variable and call an external ant script to detect changes in the SCM. When calling the external ant script the groovy script can pass in values like the time-stamp of the last successful build or the time-stamp of the last build or any additional information that the ant script requires from Jenkins. All the logic to determine the parameters that need to be passed to the ant script should be written in the groovy script. The logic to detect changes in the SCM should be written in the ant script.


plugin-scm plugin-scm Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.