How to customize the snapshot name created by automated build?
Accepted answer
to make the build behave differently, you would have to write a build participant as per the description in this forum entry. The Build FAQ also points to that entry.
It might be easier and more pragmatic to simply rename the snapshot after creation. You can do this manually by following the link to the associated snapshot from the build results object, opening the snapshot and simply replacing its name, then save.
Possibly a post-build participant which renames the snapshot would be able to automate this. But it is probably as much work to simply write a new build participant.
Does this help? Then please mark it as accepted answer.
- Arne
Comments
I would add that if you want that functionality out of the box you can open a RFE so it can be considered for inclusion in a later release. However currently there is no automated out of the box solution for what you describe. I would say that the actual name of snapshot is not THAT important since it would be linked to the build result which would match your version criteria for the snapshot. So changing your work flow from looking at the stream history to pick out the build snapshot, to finding the relevant build result and then navigating to the snapshot associated to that build.
1 vote
Thanks for your answer Arne!
What do you mean by build participant? Am I supposed to write some eclipse plugin described in the article below? Then is it possible to get the build number in the plugin? The build number is stored in a property of Ant script.
https://jazz.net/blog/index.php/2012/12/06/how-we-save-time-with-build-engine-participants-and-you-can-too/
I want to customize the snapshot name for two reasons.
1. I'd like to include the build number in the email sent by JBE. The subject of the email seems to contain the snapshot name.
2. A better name makes more sense.