The first(Andrew) and the last comment (Brian) explains it all.. In general in Maven you do not invoke goals directly, but instead you invoke the phase that the goal is bound to (or any later phase)
The example code binds the goal to the package phase, and also puts the configuration for that binding into the execution. Therefore when you run the goal directly from the CLI as "mvn dependency:unpack" the plugin is missing its required configuration because the configuration is contained within a lifecycle execution. The example illustrated best practice, which is what examples should do. If you read the second half of the page you link: http://maven.apache.org/plugins/maven-dependency-plugin/examples/unpacking-artifacts.html#Unpacking_from_the_command_line It will tell you how to make things work the way you are trying to make them work, but you should only do that while trying to figure out how to use the plugin. Once you have that figured out, move the configuration back into an execution (or if it is something that is only occasional, move it into a profile or best an execution in a profile) and just use the lifecycle to invoke it as needed -Stephen On 22 March 2011 12:28, TomazM <tomaz.majerh...@arnes.si> wrote: > On this site http://jira.codehaus.org/browse/MDEP-163 you have a bug > report, but this gay saying that this is not a bug, what else is then. > > ---------------------------------------- > Dan Tran made changes - 31/Dec/09 5:57 PM > Status Open [ 1 ] Closed [ 6 ] > Resolution Not A Bug [ 6 ] > --------------------------------------- > > If you are distributing something and basic example from your site > > http://maven.apache.org/plugins/maven-dependency-plugin/examples/unpacking-artifacts.html > > throw an exception: > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-dependency-plugin:2.2:unpack (default-cli) on > project ozwizard_lu_dev: The parameters > 'artifactItems' for goal > org.apache.maven.plugins:maven-dependency-plugin:2.2:unpack are missing or > invalid -> [Help 1] > > > 1) Or change your documentation how to use it > 2) Or actually look and test for your bug > > > Regards, Tomaz > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org >