maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jvan...@apache.org
Subject svn commit: r726579 - in /maven/components/trunk/maven-embedder/src/main/java/org/apache/maven: cli/CLIRequestUtils.java embedder/MavenEmbedder.java embedder/execution/DefaultMavenExecutionRequestPopulator.java
Date Sun, 14 Dec 2008 23:49:30 GMT
Author: jvanzyl
Date: Sun Dec 14 15:49:30 2008
New Revision: 726579

URL: http://svn.apache.org/viewvc?rev=726579&view=rev
Log:
o remove standalone property

Modified:
    maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/cli/CLIRequestUtils.java
    maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/MavenEmbedder.java
    maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/execution/DefaultMavenExecutionRequestPopulator.java

Modified: maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/cli/CLIRequestUtils.java
URL: http://svn.apache.org/viewvc/maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/cli/CLIRequestUtils.java?rev=726579&r1=726578&r2=726579&view=diff
==============================================================================
--- maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/cli/CLIRequestUtils.java
(original)
+++ maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/cli/CLIRequestUtils.java
Sun Dec 14 15:49:30 2008
@@ -19,13 +19,6 @@
  * under the License.
  */
 
-import org.apache.commons.cli.CommandLine;
-import org.apache.maven.MavenTransferListener;
-import org.apache.maven.embedder.MavenEmbedder;
-import org.apache.maven.execution.DefaultMavenExecutionRequest;
-import org.apache.maven.execution.MavenExecutionRequest;
-import org.codehaus.plexus.util.cli.CommandLineUtils;
-
 import java.io.File;
 import java.io.IOException;
 import java.util.ArrayList;
@@ -35,6 +28,12 @@
 import java.util.StringTokenizer;
 import java.util.Map.Entry;
 
+import org.apache.commons.cli.CommandLine;
+import org.apache.maven.MavenTransferListener;
+import org.apache.maven.execution.DefaultMavenExecutionRequest;
+import org.apache.maven.execution.MavenExecutionRequest;
+import org.codehaus.plexus.util.cli.CommandLineUtils;
+
 public final class CLIRequestUtils
 {
 
@@ -258,9 +257,6 @@
 
     static void populateProperties( CommandLine commandLine, Properties executionProperties,
Properties userProperties )
     {
-        System.setProperty( MavenEmbedder.STANDALONE_MODE, "true" );
-        executionProperties.setProperty( MavenEmbedder.STANDALONE_MODE, "true" );
-
         // add the env vars to the property set, with the "env." prefix
         // XXX support for env vars should probably be removed from the ModelInterpolator
         try

Modified: maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/MavenEmbedder.java
URL: http://svn.apache.org/viewvc/maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/MavenEmbedder.java?rev=726579&r1=726578&r2=726579&view=diff
==============================================================================
--- maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/MavenEmbedder.java
(original)
+++ maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/MavenEmbedder.java
Sun Dec 14 15:49:30 2008
@@ -122,9 +122,6 @@
     public static final File DEFAULT_GLOBAL_SETTINGS_FILE =
         new File( System.getProperty( "maven.home", System.getProperty( "user.dir", "" )
), "conf/settings.xml" );
 
-    public static final String STANDALONE_MODE = "maven.mode.standalone";
-
-
     // ----------------------------------------------------------------------------
     //
     // ----------------------------------------------------------------------------

Modified: maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/execution/DefaultMavenExecutionRequestPopulator.java
URL: http://svn.apache.org/viewvc/maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/execution/DefaultMavenExecutionRequestPopulator.java?rev=726579&r1=726578&r2=726579&view=diff
==============================================================================
--- maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/execution/DefaultMavenExecutionRequestPopulator.java
(original)
+++ maven/components/trunk/maven-embedder/src/main/java/org/apache/maven/embedder/execution/DefaultMavenExecutionRequestPopulator.java
Sun Dec 14 15:49:30 2008
@@ -155,13 +155,6 @@
             request.setProperties( requestProperties );
         }
 
-        if ( requestProperties.getProperty( MavenEmbedder.STANDALONE_MODE ) == null )
-        {
-            // TODO: Remove this!
-            System.setProperty( MavenEmbedder.STANDALONE_MODE, "true" );
-            requestProperties.setProperty( MavenEmbedder.STANDALONE_MODE, "true" );
-        }
-
         Properties userProperties = request.getUserProperties();
         if ( userProperties != null )
         {
@@ -176,8 +169,7 @@
         }
     }
 
-    private void realmManager( MavenExecutionRequest request,
-                               Configuration configuration )
+    private void realmManager( MavenExecutionRequest request, Configuration configuration
)
     {
         if ( request.getRealmManager() == null )
         {
@@ -192,8 +184,7 @@
         }
     }
 
-    private void processSettings( MavenExecutionRequest request,
-                                  Configuration configuration )
+    private void processSettings( MavenExecutionRequest request, Configuration configuration
)
     {
         ProfileManager profileManager = request.getProfileManager();
 
@@ -263,8 +254,7 @@
     // POM
     // ------------------------------------------------------------------------
 
-    private void pom( MavenExecutionRequest request,
-                      Configuration configuration )
+    private void pom( MavenExecutionRequest request, Configuration configuration )
     {
         // ------------------------------------------------------------------------
         // POM
@@ -301,8 +291,7 @@
     // Settings
     // ------------------------------------------------------------------------
 
-    private void settings( MavenExecutionRequest request,
-                           Configuration configuration )
+    private void settings( MavenExecutionRequest request, Configuration configuration )
     {
         // ------------------------------------------------------------------------
         // Settings
@@ -397,12 +386,6 @@
     private void checksumPolicy( MavenExecutionRequest request,
                                  Configuration configuration )
     {
-        // ------------------------------------------------------------------------
-        // Repository Checksum Policies
-        //
-        // We take the checksum passed in via the request.
-        // ------------------------------------------------------------------------
-
         mavenTools.setGlobalChecksumPolicy( request.getGlobalChecksumPolicy() );
     }
 
@@ -410,14 +393,11 @@
     // Artifact Transfer Mechanism
     // ------------------------------------------------------------------------
 
-    private void artifactTransferMechanism( MavenExecutionRequest request,
-                                            Configuration configuration )
+    private void artifactTransferMechanism( MavenExecutionRequest request, Configuration
configuration )
         throws MavenEmbedderException
     {
         // ------------------------------------------------------------------------
         // Artifact Transfer Mechanism
-        //
-        //
         // ------------------------------------------------------------------------
 
         if ( request.isOffline() )
@@ -445,9 +425,7 @@
         }
         catch ( Exception e )
         {
-            throw new MavenEmbedderException(
-                "Unable to configure Maven for execution",
-                e );
+            throw new MavenEmbedderException( "Unable to configure Maven for execution",
e );
         }
     }
 
@@ -467,36 +445,20 @@
                     throw new SettingsConfigurationException( "Proxy in settings.xml has
no host" );
                 }
 
-                wagonManager.addProxy(
-                    proxy.getProtocol(),
-                    proxy.getHost(),
-                    proxy.getPort(),
-                    proxy.getUsername(),
-                    proxy.getPassword(),
-                    proxy.getNonProxyHosts() );
+                wagonManager.addProxy( proxy.getProtocol(), proxy.getHost(), proxy.getPort(),
proxy.getUsername(), proxy.getPassword(), proxy.getNonProxyHosts() );
             }
 
             for ( Iterator i = settings.getServers().iterator(); i.hasNext(); )
             {
                 Server server = (Server) i.next();
 
-                wagonManager.addAuthenticationInfo(
-                    server.getId(),
-                    server.getUsername(),
-                    server.getPassword(),
-                    server.getPrivateKey(),
-                    server.getPassphrase() );
-
-                wagonManager.addPermissionInfo(
-                    server.getId(),
-                    server.getFilePermissions(),
-                    server.getDirectoryPermissions() );
+                wagonManager.addAuthenticationInfo( server.getId(), server.getUsername(),
server.getPassword(), server.getPrivateKey(), server.getPassphrase() );
+
+                wagonManager.addPermissionInfo( server.getId(), server.getFilePermissions(),
server.getDirectoryPermissions() );
 
                 if ( server.getConfiguration() != null )
                 {
-                    wagonManager.addConfiguration(
-                        server.getId(),
-                        (Xpp3Dom) server.getConfiguration() );
+                    wagonManager.addConfiguration( server.getId(), (Xpp3Dom) server.getConfiguration()
);
                 }
             }
 
@@ -512,10 +474,7 @@
             {
                 Mirror mirror = (Mirror) i.next();
 
-                wagonManager.addMirror(
-                    mirror.getId(),
-                    mirror.getMirrorOf(),
-                    mirror.getUrl() );
+                wagonManager.addMirror( mirror.getId(), mirror.getMirrorOf(), mirror.getUrl()
);
             }
         }
         finally
@@ -524,9 +483,7 @@
         }
     }
 
-    public ArtifactRepository createLocalRepository( MavenExecutionRequest request,
-                                                     Settings settings,
-                                                     Configuration configuration ) 
+    public ArtifactRepository createLocalRepository( MavenExecutionRequest request, Settings
settings, Configuration configuration ) 
         throws MavenEmbedderException
     {
         String localRepositoryPath = null;
@@ -596,8 +553,7 @@
     // Profile Manager
     // ------------------------------------------------------------------------
 
-    private void profileManager( MavenExecutionRequest request,
-                                 Configuration configuration )
+    private void profileManager( MavenExecutionRequest request, Configuration configuration
)
     {
         // ------------------------------------------------------------------------
         // Profile Manager



Mime
View raw message