You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Paul Benedict (JIRA)" <ji...@codehaus.org> on 2008/02/01 17:43:57 UTC
[jira] Commented: (MNG-3368) Printing version (-v argument) should
not stop lifecycle execution
[ http://jira.codehaus.org/browse/MNG-3368?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_122063 ]
Paul Benedict commented on MNG-3368:
------------------------------------
I believe the fix is easy. Two use cases have to be supported:
1) If --version and no phase specified, then print version and quit. This prevents the "You must specify at least one goal" message.
2) If --version and phase(s) specified, then print version and continue.
The change needs to be made in org.apache.maven.cli.MavenCli
Line 142 has this:
if ( commandLine.hasOption( CLIManager.VERSION ) )
{
showVersion();
if ( // *** Add second condition ) {
return 0;
}
}
> Printing version (-v argument) should not stop lifecycle execution
> ------------------------------------------------------------------
>
> Key: MNG-3368
> URL: http://jira.codehaus.org/browse/MNG-3368
> Project: Maven 2
> Issue Type: Bug
> Components: Bootstrap & Build, Command Line
> Affects Versions: 2.0.8
> Reporter: Paul Benedict
>
> I wanted to always print the Maven version when I build, but unfortunately Maven immediately quits after outputting the version. This option should not quit when a lifecycle is also specified. Example: mvn -v install
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira