maven 2 - How to attach an artifact with assembly-plugin during custom lifecycle -
i'm trying create plugin custom lifecycle :
/** * @goal my-goal * @execute lifecycle="my-custom-lifecycle" phase="attach-foo" */ public class mymojo extends abstractmojo { ...
with src/main/resources/meta-inf/maven/lifecycle.xml file :
<lifecycles> <lifecycle> <id>attach-foo</id> <phases> <phase> <id>package</id> <executions> <execution> <goals> <goal> org.apache.maven.plugins:maven-assembly-plugin:single </goal> </goals> <configuration> <descriptorrefs> <descriptor>adescriptor.xml</descriptor> </descriptorrefs> </configuration> </execution> </executions> </phase> </phases> </lifecycle> </lifecycles>
assembly-plugin called unfortunately zip artifact generated not attached , install in repo...
any ideas ?
thanks
which version of maven-assembly-plugin used? per plugin docs, there optional parameter attach
available in versions 2.2-beta-1 , later. value defaults true
meaning created artifact should end in repository.
Comments
Post a Comment