maven-scm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From eveni...@apache.org
Subject svn commit: r518634 - in /maven/scm/trunk: maven-scm-api/src/main/java/org/apache/maven/scm/manager/ maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/ maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/src/main/j...
Date Thu, 15 Mar 2007 14:14:07 GMT
Author: evenisse
Date: Thu Mar 15 07:14:07 2007
New Revision: 518634

URL: http://svn.apache.org/viewvc?view=rev&rev=518634
Log:
[SCM-286] Allow two provider implementations in classpath

Modified:
    maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/manager/AbstractScmManager.java
    maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/pom.xml
    maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/src/main/java/org/apache/maven/scm/provider/cvslib/cvsexe/CvsExeScmProvider.java

Modified: maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/manager/AbstractScmManager.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/manager/AbstractScmManager.java?view=diff&rev=518634&r1=518633&r2=518634
==============================================================================
--- maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/manager/AbstractScmManager.java
(original)
+++ maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/manager/AbstractScmManager.java
Thu Mar 15 07:14:07 2007
@@ -108,11 +108,18 @@
             }
         }
 
-        ScmProvider scmProvider = (ScmProvider) scmProviders.get( providerType );
+        String usedProviderType = System.getProperty( "maven.scm.provider." + providerType
+ ".implementation" );
+
+        if ( usedProviderType == null )
+        {
+            usedProviderType = providerType;
+        }
+
+        ScmProvider scmProvider = (ScmProvider) scmProviders.get( usedProviderType );
 
         if ( scmProvider == null )
         {
-            throw new NoSuchScmProviderException( providerType );
+            throw new NoSuchScmProviderException( usedProviderType );
         }
 
         return scmProvider;

Modified: maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/pom.xml
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/pom.xml?view=diff&rev=518634&r1=518633&r2=518634
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/pom.xml
(original)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/pom.xml
Thu Mar 15 07:14:07 2007
@@ -54,6 +54,18 @@
           </execution>
         </executions>
       </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <systemProperties>
+            <property>
+              <name>maven.scm.provider.cvs.implementation</name>
+              <value>cvs_native</value>
+            </property>
+          </systemProperties>
+        </configuration>
+      </plugin>
     </plugins>
   </build>
 </project>

Modified: maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/src/main/java/org/apache/maven/scm/provider/cvslib/cvsexe/CvsExeScmProvider.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/src/main/java/org/apache/maven/scm/provider/cvslib/cvsexe/CvsExeScmProvider.java?view=diff&rev=518634&r1=518633&r2=518634
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/src/main/java/org/apache/maven/scm/provider/cvslib/cvsexe/CvsExeScmProvider.java
(original)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvsexe/src/main/java/org/apache/maven/scm/provider/cvslib/cvsexe/CvsExeScmProvider.java
Thu Mar 15 07:14:07 2007
@@ -36,7 +36,7 @@
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
  * @version $Id$
- * @plexus.component role="org.apache.maven.scm.provider.ScmProvider" role-hint="cvs"
+ * @plexus.component role="org.apache.maven.scm.provider.ScmProvider" role-hint="cvs_native"
  */
 public class CvsExeScmProvider
     extends AbstractCvsScmProvider



Mime
View raw message