Why not limit your plugin to generating the sources, and use the existing plugins for compiling and packaging? This is likely to be more flexible, plus it's a lot less work.
If you want different artifactIds for each bundle, you should use a separate module for each. But you could also put them all into one module if you wanted to use classifiers. Then you'd get names like this: - generated-1.0-j2me.jar - generated-1.0-j2se.jar - generated-1.0-ansi-c.zip Paul Tomas Carlsson wrote: > > Hi, > > We have a tool that given one input file generates code for different > purposes (currently j2me, j2se, ansi-c). I'm planning to write an m2 > plugin > for this tool but I'm not really sure how to do it. > > What I'm trying to achieve is to only have one copy of the original input > file and whenever it is changed there should be a simple build/release > step > generating the result deliverables where the different types of > deliverables > preferably has the same version number (ie. "generated-j2me-1.0.jar", " > generated-j2se-1.0.jar", "generated-ansi-c-1.0.zip") > > My initial thought is to create a plugin that first generates sources for > the different purposes, then compiles them and lastly packages one archive > for each type. > > I.e: > 1 input file => 3 generated source trees => 3 compiled "classes" tress > => > 3 packed archetypes > > I'm seeing some trouble with this though: > > 1. It violates the maven philosophy of only having one archetype > 2. The plugin seems to get quite complicated which I think should be > possible to avoid > > > Anyone having experience with this kind of setup? Any best practices out > there? > > > best regards > Tomas > > -- View this message in context: http://www.nabble.com/Best-practice-for-source-generating-multiple-archetype-plugin-tf2622203s177.html#a7361402 Sent from the Maven - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
