You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by gn...@apache.org on 2021/12/13 12:48:31 UTC
[maven] branch MNG-7354 created (now 268d7d0)
This is an automated email from the ASF dual-hosted git repository.
gnodet pushed a change to branch MNG-7354
in repository https://gitbox.apache.org/repos/asf/maven.git.
at 268d7d0 Make ExitException constructor public
This branch includes the following new commits:
new c6e1a73 Make CLIManager usable outside the o.a..m.cli package
new 2277caf Make ExitException protected
new 513b41e Make CliRequest usable outside package
new e34a954 Make CLIreportingUtils#getBuildProperties() public
new 268d7d0 Make ExitException constructor public
The 5 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[maven] 05/05: Make ExitException constructor public
Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
gnodet pushed a commit to branch MNG-7354
in repository https://gitbox.apache.org/repos/asf/maven.git
commit 268d7d019ae7551710f863b099144b1494e302ae
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Mon Dec 13 13:45:26 2021 +0100
Make ExitException constructor public
---
maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java b/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
index 1ec834c..f955120 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
@@ -1844,7 +1844,7 @@ public class MavenCli
{
int exitCode;
- ExitException( int exitCode )
+ public ExitException( int exitCode )
{
this.exitCode = exitCode;
}
[maven] 03/05: Make CliRequest usable outside package
Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
gnodet pushed a commit to branch MNG-7354
in repository https://gitbox.apache.org/repos/asf/maven.git
commit 513b41ed38952e1f5449fa2970c2e058d6aec375
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Mon Dec 13 13:37:13 2021 +0100
Make CliRequest usable outside package
---
.../main/java/org/apache/maven/cli/CliRequest.java | 50 ++++++++++++++++++++++
1 file changed, 50 insertions(+)
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/CliRequest.java b/maven-embedder/src/main/java/org/apache/maven/cli/CliRequest.java
index 2f6adc2..09aa09e 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/CliRequest.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/CliRequest.java
@@ -116,8 +116,58 @@ public class CliRequest
return request;
}
+ public void setArgs( String[] args )
+ {
+ this.args = args;
+ }
+
+ public void setCommandLine( CommandLine commandLine )
+ {
+ this.commandLine = commandLine;
+ }
+
+ public void setClassWorld( ClassWorld classWorld )
+ {
+ this.classWorld = classWorld;
+ }
+
+ public void setWorkingDirectory( String workingDirectory )
+ {
+ this.workingDirectory = workingDirectory;
+ }
+
+ public void setMultiModuleProjectDirectory( File multiModuleProjectDirectory )
+ {
+ this.multiModuleProjectDirectory = multiModuleProjectDirectory;
+ }
+
+ public void setVerbose( boolean verbose )
+ {
+ this.verbose = verbose;
+ }
+
+ public void setQuiet( boolean quiet )
+ {
+ this.quiet = quiet;
+ }
+
+ public void setShowErrors( boolean showErrors )
+ {
+ this.showErrors = showErrors;
+ }
+
public void setUserProperties( Properties properties )
{
this.userProperties.putAll( properties );
}
+
+ public void setSystemProperties( Properties systemProperties )
+ {
+ this.systemProperties = systemProperties;
+ }
+
+ public void setRequest( MavenExecutionRequest request )
+ {
+ this.request = request;
+ }
}
\ No newline at end of file
[maven] 04/05: Make CLIreportingUtils#getBuildProperties() public
Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
gnodet pushed a commit to branch MNG-7354
in repository https://gitbox.apache.org/repos/asf/maven.git
commit e34a954aca7d2d30f480c799225b5f041ee2056b
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Mon Dec 13 13:44:33 2021 +0100
Make CLIreportingUtils#getBuildProperties() public
---
.../src/main/java/org/apache/maven/cli/CLIReportingUtils.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java b/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java
index 57be196..009a251 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/CLIReportingUtils.java
@@ -116,7 +116,7 @@ public final class CLIReportingUtils
return ( s != null ? ( s.startsWith( "${" ) && s.endsWith( "}" ) ? null : s ) : null );
}
- static Properties getBuildProperties()
+ public static Properties getBuildProperties()
{
Properties properties = new Properties();
[maven] 01/05: Make CLIManager usable outside the o.a..m.cli package
Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
gnodet pushed a commit to branch MNG-7354
in repository https://gitbox.apache.org/repos/asf/maven.git
commit c6e1a736a9e683832cbf0865504508d0bbbcb5e8
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Mon Dec 13 13:26:46 2021 +0100
Make CLIManager usable outside the o.a..m.cli package
---
maven-embedder/src/main/java/org/apache/maven/cli/CLIManager.java | 7 ++++++-
.../java/org/apache/maven/cli/CLIManagerDocumentationTest.java | 4 ++--
2 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/CLIManager.java b/maven-embedder/src/main/java/org/apache/maven/cli/CLIManager.java
index 49bf9db..7da7b3a 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/CLIManager.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/CLIManager.java
@@ -115,7 +115,7 @@ public class CLIManager
@Deprecated
public static final String DEBUG = "debug";
- protected Options options;
+ protected final Options options;
@SuppressWarnings( "checkstyle:linelength" )
public CLIManager()
@@ -163,6 +163,11 @@ public class CLIManager
options.addOption( Option.builder().longOpt( DEBUG ).desc( "Produce execution verbose output (deprecated; only kept for backward compatibility)" ).build() );
}
+ public Options getOptions()
+ {
+ return options;
+ }
+
public CommandLine parse( String[] args )
throws ParseException
{
diff --git a/maven-embedder/src/test/java/org/apache/maven/cli/CLIManagerDocumentationTest.java b/maven-embedder/src/test/java/org/apache/maven/cli/CLIManagerDocumentationTest.java
index a652eda..a98cf17 100644
--- a/maven-embedder/src/test/java/org/apache/maven/cli/CLIManagerDocumentationTest.java
+++ b/maven-embedder/src/test/java/org/apache/maven/cli/CLIManagerDocumentationTest.java
@@ -53,7 +53,7 @@ public class CLIManagerDocumentationTest
private static class CLIManagerExtension
extends CLIManager
{
- public Collection<Option> getOptions()
+ public List<Option> getOptionList()
{
List<Option> optList = new ArrayList<>( options.getOptions() );
Collections.sort( optList, new OptionComparator() );
@@ -66,7 +66,7 @@ public class CLIManagerDocumentationTest
StringBuilder sb = new StringBuilder( 512 );
boolean a = true;
sb.append( "<table border='1' class='zebra-striped'><tr class='a'><th><b>Options</b></th><th><b>Description</b></th></tr>" );
- for ( Option option : new CLIManagerExtension().getOptions() )
+ for ( Option option : new CLIManagerExtension().getOptionList() )
{
a = !a;
sb.append( "<tr class='" ).append( a ? 'a' : 'b' ).append( "'><td><code>-<a name='" );
[maven] 02/05: Make ExitException protected
Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
gnodet pushed a commit to branch MNG-7354
in repository https://gitbox.apache.org/repos/asf/maven.git
commit 2277caf2666bf0b9563dc32408362968cd9bb761
Author: Guillaume Nodet <gn...@gmail.com>
AuthorDate: Mon Dec 13 13:34:33 2021 +0100
Make ExitException protected
---
maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java b/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
index de70108..1ec834c 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
@@ -1839,7 +1839,7 @@ public class MavenCli
System.setProperty( name, value );
}
- static class ExitException
+ protected static class ExitException
extends Exception
{
int exitCode;