On Tue, Apr 14, 2015 at 3:00 PM, nfwlpw <nfw...@gmail.com> wrote:
> We have a single SVN repo broken up into sub projects, Proj1 must be built
> first, followed by Proj2.  The problem is Proj1 takes a few hours so during
> which time someone could've checked something into Proj2, so I want to make
> sure Proj2 uses the revision used by Proj1.  I've been thinking how to
> tackle this.
>
> Option 1: give the build flow a REVISION parameter and pass that to all the
> jobs, but then you have to enter it each time (obviously I can't set it as
> HEAD since that is what I want to avoid).  Proj1 needs to return the
> revision and Proj2 needs to read it
>
> Option 2: timestamp.  Somehow the build flow get the timestamp and pass it
> to all the jobs.  However I have to massage it into a format SVN can accept.
> Is it possible with the DSL?
>
> Option 3: Have an Init job before build flow, and let it figure out what the
> SVN revision is, then call build flow with that revision.
>
> Anyone done something similar?

Assuming you really mean build_flow and not workflow, you can make
proj2 a parameterized job to pass REVISION  like:

b1=build("Proj1")
b2=build("Proj2",REVISION: b1.build.properties.envVars["SVN_REVISION"] )

-- 
   Les Mikesell
     lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAOAgVpzLTf6EiGso4MrJ6crFdDBmaCrgtC%3Dit_rqocwsUsFYAg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to