Description doesn't match the code, see below...
[EMAIL PROTECTED] wrote:
Author: brett
Date: Tue Aug 8 18:39:59 2006
New Revision: 429917
URL: http://svn.apache.org/viewvc?rev=429917&view=rev
Log:
add quiet option. Some plugins will need work.
Modified:
maven/components/branches/maven-2.0.x/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java
Modified:
maven/components/branches/maven-2.0.x/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java
URL:
http://svn.apache.org/viewvc/maven/components/branches/maven-2.0.x/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java?rev=429917&r1=429916&r2=429917&view=diff
==============================================================================
---
maven/components/branches/maven-2.0.x/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java
(original)
+++
maven/components/branches/maven-2.0.x/maven-core/src/main/java/org/apache/maven/cli/MavenCli.java
Tue Aug 8 18:39:59 2006
@@ -194,6 +194,13 @@
{
loggerManager.setThreshold( Logger.LEVEL_DEBUG );
}
+ else if ( commandLine.hasOption( CLIManager.QUIET ) )
+ {
+ // TODO: we need to do some more work here. Some plugins use
sys out or log errors at info level.
+ // Ideally, we could use Warn across the board
+ loggerManager.setThreshold( Logger.LEVEL_ERROR );
Set Threshold to error
+ // TODO:Additionally, we can't change the mojo level because
the component key includes the version and it isn't known ahead of time. This
seems worth changing.
+ }
ProfileManager profileManager = new DefaultProfileManager( embedder.getContainer() );
@@ -601,6 +608,8 @@
public static final char REACTOR = 'r';
+ public static final char QUIET = 'q';
+
public static final char DEBUG = 'X';
public static final char ERRORS = 'e';
@@ -654,6 +663,9 @@
options.addOption(
OptionBuilder.withLongOpt( "version" ).withDescription( "Display
version information" ).create(
VERSION ) );
+ options.addOption(
+ OptionBuilder.withLongOpt( "quiet" ).withDescription( "Quiet output
- only show warnings and errors" ).create(
+ QUIET ) );
Document it as warnings and errors
options.addOption(
OptionBuilder.withLongOpt( "debug" ).withDescription( "Produce
execution debug output" ).create(
DEBUG ) );
--
Dennis Lundberg
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]