Hi Guys,

I'm updating the pipeline support for the 'p4' plugin and trying to workout 
how the plugin should react to the two stages of checkout.

For example: creating a pipeline Job, then configuring 'Pipeline Script 
from SCM' and providing the details of where to get the Jenkinsfile.

The first checkout creates a workspace directory 'jobName@script/' and 
syncs the Jenkinsfile:

node ('master') {

       stage 'CheckOut'

       checkout scm

}


The second checkout is invoked by the `checkout scm` in the Jenkinsfile, 
but how does the 'p4' plugin know how to checkout? It gets called with the 
same configuration used in the first stage, so all you end up with is a 
workspace directory 'jobName/' and just the Jenkinsfile?


I can hack the behaviour to look for the '@script', but this seems bad, is 
there any other way to differentiate between the two calls to:


@Override
public void checkout(Run<?, ?> run, Launcher launcher, FilePath 
buildWorkspace, TaskListener listener,
          File changelogFile, SCMRevisionState baseline) throws IOException, 
InterruptedException {


Thanks,

Paul

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/5b7f24c6-1723-41a3-84df-ae3cc0e654f1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to