Manually creating builds
![](http://jazz.net/_images/myphoto/3954f0f9b5bafb14621c8a01a1084af5.jpg)
Hi all,
Currently, we cannot use the build engine for building. We build, test, and package manually or by tools that are not integrated yet.
However, I would like to manually create a build as the build engine does and attach all my build artifacts to it, to be able to file new defects against that build. The build should also create a snapshot and I would like to be able to create a release from that build.
In other words, I just want to create a build entity as the build engine does.
Is that possible?
Thanks a lot,
Timo
Currently, we cannot use the build engine for building. We build, test, and package manually or by tools that are not integrated yet.
However, I would like to manually create a build as the build engine does and attach all my build artifacts to it, to be able to file new defects against that build. The build should also create a snapshot and I would like to be able to create a release from that build.
In other words, I just want to create a build entity as the build engine does.
Is that possible?
Thanks a lot,
Timo
3 answers
![](http://jazz.net/_images/myphoto/3954f0f9b5bafb14621c8a01a1084af5.jpg)
Hi all,
Currently, we cannot use the build engine for building. We build, test, and package manually or by tools that are not integrated yet.
However, I would like to manually create a build as the build engine does and attach all my build artifacts to it, to be able to file new defects against that build. The build should also create a snapshot and I would like to be able to create a release from that build.
In other words, I just want to create a build entity as the build engine does.
Is that possible?
Thanks a lot,
Timo
Hi Timo
Could you use an build that does nothing - ie the command it runs is empty or simply returns Pass. Then, before the build is run, create a work item that is associated with the build (you will probably need to deliver something and associate the work item with the delivery). Afterwards, use the work item to hold any information that is not part of the snapshot.
anthony
![](http://jazz.net/_images/myphoto/3954f0f9b5bafb14621c8a01a1084af5.jpg)
Depends on your needs you could do as Anthony mentioned and just create the placeholder, if this is a release build or something that you need to do with some of the artifacts attached you could build on that and create a simple build script that pulls from your existing build results and puts them into the build result in RTC.
Take a look at the Info Center ant task for an idea of what I mean in particular around contributing build artifacts.
http://publib.boulder.ibm.com/infocenter/rtc/v2r0m0/topic/com.ibm.team.build.doc/topics/r_publishbuildresult.html
http://publib.boulder.ibm.com/infocenter/rtc/v2r0m0/index.jsp?topic=/com.ibm.team.build.doc/topics/r_ant-tasks.html
-Sean
Take a look at the Info Center ant task for an idea of what I mean in particular around contributing build artifacts.
http://publib.boulder.ibm.com/infocenter/rtc/v2r0m0/topic/com.ibm.team.build.doc/topics/r_publishbuildresult.html
http://publib.boulder.ibm.com/infocenter/rtc/v2r0m0/index.jsp?topic=/com.ibm.team.build.doc/topics/r_ant-tasks.html
-Sean
![](http://jazz.net/_images/myphoto/3954f0f9b5bafb14621c8a01a1084af5.jpg)
The simplest approach would be to create a command line build definition, configured with Jazz Source Control. The command line would invoke your build script. If you can use JBE, then it would pick up the build (either manually requested or scheduled), do the Jazz SCM work (accepting changes into the build workspace, creating the snapshot, then fetching the contents), then invoke the command line. If you're using Ant or Maven, you could use the corresponding build definitions instead.
If you really can't use JBE, e.g. because some other build system needs to drive the process, you can still create a Jazz build result and do the accept/fetch (with snapshot creation) using the Ant tasks in the Build Toolkit.
You would still set up a corresponding build definition and build engine item, but then script the build yourself using:
<tstamp>
<format property="buildLabel" pattern="yyyyMMdd-hhmm"/>
</tstamp>
<startTeamBuild buildDefinitionId="your.definition.id" engineId="your.engine.id" label="${buildLabel}" resultUUIDProperty="buildResultUUID" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
<teamAccept buildResultUUID="${buildResultUUID}" workspaceName="Your Build Workspace Name" snapshotName="Snapshot-${buildLabel}" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
<teamFetch buildResultUUID="${buildResultUUID}" workspaceName="Your Build Workspace Name" destination="/some/load/directory" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
... do your work
<completeTeamBuild buildResultUUID="${buildResultUUID}" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
This approach is illustrated further in the 'standalone' example included in the Build System Toolkit. See {installDir}/buildsystem/buildtoolkit/examples/standalone/build.xml.
See the links above for more details on the Ant tasks.
Regards,
Nick
If you really can't use JBE, e.g. because some other build system needs to drive the process, you can still create a Jazz build result and do the accept/fetch (with snapshot creation) using the Ant tasks in the Build Toolkit.
You would still set up a corresponding build definition and build engine item, but then script the build yourself using:
<tstamp>
<format property="buildLabel" pattern="yyyyMMdd-hhmm"/>
</tstamp>
<startTeamBuild buildDefinitionId="your.definition.id" engineId="your.engine.id" label="${buildLabel}" resultUUIDProperty="buildResultUUID" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
<teamAccept buildResultUUID="${buildResultUUID}" workspaceName="Your Build Workspace Name" snapshotName="Snapshot-${buildLabel}" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
<teamFetch buildResultUUID="${buildResultUUID}" workspaceName="Your Build Workspace Name" destination="/some/load/directory" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
... do your work
<completeTeamBuild buildResultUUID="${buildResultUUID}" repositoryAddress="${repositoryAddress}" userId="${userId}" passwordFile="${passwordFile}"/>
This approach is illustrated further in the 'standalone' example included in the Build System Toolkit. See {installDir}/buildsystem/buildtoolkit/examples/standalone/build.xml.
See the links above for more details on the Ant tasks.
Regards,
Nick