Re: Generation of checksums of files included in assembly
Hi, Thanks but I'm not sure it goes really far from generating checksum of a unique file, and my problem is more how to generate checksums of inner content of tar.gz or zip archive ... And where to locate this in maven life-cycle. I had this idea, but I'm not sure on feasibility, implemented in a maven plugin : 1- associate this new plugin execution to prepare-package 2- in this maven plugin, add @execute goal=assembly:single (or assembly:directory would be fine but deprecated) to generate tar.gz (or zip) during prepare-package 3- add java/groovy in execute() to unpack the archive, compute checksums and generate summary file for inner content 4- copy this file somewhere it will be picked up by the assembly during tar.gz (or zip) generation I'm really not sure of the @execute in a maven plugin mojo ... I'm assuming it's a way to call another goal of another plugin from within my custom plugin execution, but is this really likely to work ? I'm not sure also if assembly:single will then be called during package phase, as it should ? I imagine I could also call gmaven-plugin and execute some groovy script to do the job ... Any comments welcome ... -- View this message in context: http://maven.40175.n5.nabble.com/Generation-of-checksums-of-files-included-in-assembly-tp4708215p4715512.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Generation of checksums of files included in assembly
Hello, I'm asking for some help on implementing / improving this feature commonly used in my enterprise builds. Objective is to generate a specific traceability file, for modules generating tar.gz assembly, with the list of files contained in the tar.gz along with their checksum. Constraints are : solution must be implemented in only one module, and easy to customize/understand. Tar.gz assembly can come from predefined assembly (packaged in jar) or assembly.xml in module sources. Idea already in place to implement this is as follow (simplified) : - Assembly:directory-single: generates tar.gz exploded as a folder - Antrun:run: generates file with list of checksums against exploded folder - Assembly:single: generates tar.gz included checksum file Problems are that : - Use of directory-single is deprecated, to avoid it I would need to either : o Use 2 formats in assemblies (dir + tar.gz) and execute them twice (using dir the first time and tar.gz the second time) -- performance issue ... ? o Create 2 distinct assemblies with a different format -- duplication issue, not user-friendly - It leads to quite complex plugins configurations where order is supremely important, and difficult to understand, and any subtle variation can make the whole thing fail ... Questions are : - Is there an easier and more maven-style way to achieve this need ? - I'd like to make this feature a plugin, but as it would need to be executed other more than one phase, I don't know how to proceed or where to start ... Thanks, Jeremie B.
Re: Generation of checksums of files included in assembly
Hi, i could remember a time a go https://github.com/nicoulaj/maven-checksum-plugin which might go into the direction you are thinking of Kind regards Karl Heinz Marbaise -- SoftwareEntwicklung Beratung SchulungTel.: +49 (0) 2405 / 415 893 Dipl.Ing.(FH) Karl Heinz MarbaiseICQ#: 135949029 Hauptstrasse 177 USt.IdNr: DE191347579 52146 Würselen http://www.soebes.de - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org