maven-scm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vsive...@apache.org
Subject svn commit: r691197 - in /maven/scm/trunk: maven-scm-api/src/main/java/org/apache/maven/scm/command/changelog/ maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvs-commons/src/main/java/org/apache/maven/scm/provider/cvslib/command/changelog/
Date Tue, 02 Sep 2008 10:57:26 GMT
Author: vsiveton
Date: Tue Sep  2 03:57:26 2008
New Revision: 691197

URL: http://svn.apache.org/viewvc?rev=691197&view=rev
Log:
SCM-343: Changelog can be generated with only an end-tag
Submitted by: Roland Asmann
Reviewed by: Vincent Siveton

o patch applied using StringBuffer instead of String

Modified:
    maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/command/changelog/AbstractChangeLogCommand.java
    maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvs-commons/src/main/java/org/apache/maven/scm/provider/cvslib/command/changelog/AbstractCvsChangeLogCommand.java

Modified: maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/command/changelog/AbstractChangeLogCommand.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/command/changelog/AbstractChangeLogCommand.java?rev=691197&r1=691196&r2=691197&view=diff
==============================================================================
--- maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/command/changelog/AbstractChangeLogCommand.java
(original)
+++ maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/command/changelog/AbstractChangeLogCommand.java
Tue Sep  2 03:57:26 2008
@@ -72,7 +72,7 @@
 
         String datePattern = parameters.getString( CommandParameter.CHANGELOG_DATE_PATTERN,
null );
 
-        if ( startVersion != null && StringUtils.isNotEmpty( startVersion.getName()
) )
+        if ( startVersion != null )
         {
             return executeChangeLogCommand( repository, fileSet, startVersion, endVersion,
datePattern );
         }

Modified: maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvs-commons/src/main/java/org/apache/maven/scm/provider/cvslib/command/changelog/AbstractCvsChangeLogCommand.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvs-commons/src/main/java/org/apache/maven/scm/provider/cvslib/command/changelog/AbstractCvsChangeLogCommand.java?rev=691197&r1=691196&r2=691197&view=diff
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvs-commons/src/main/java/org/apache/maven/scm/provider/cvslib/command/changelog/AbstractCvsChangeLogCommand.java
(original)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-providers-cvs/maven-scm-provider-cvs-commons/src/main/java/org/apache/maven/scm/provider/cvslib/command/changelog/AbstractCvsChangeLogCommand.java
Tue Sep  2 03:57:26 2008
@@ -98,12 +98,21 @@
             cl.createArg().setValue( "-r" + branch.getName() );
         }
 
-        if ( startVersion != null && StringUtils.isNotEmpty( startVersion.getName()
) )
+        if ( startVersion != null  || endVersion != null )
         {
-            String param = "-r" + startVersion.getName() + ":"
-                + ( endVersion != null && StringUtils.isNotEmpty( endVersion.getName()
) ? endVersion.getName() : "" );
+            StringBuffer sb = new StringBuffer();
+            sb.append( "-r" );
+            if ( startVersion != null && StringUtils.isNotEmpty( startVersion.getName()
) )
+            {
+                sb.append( startVersion.getName() );
+            }
+            sb.append( "::" );
+            if ( endVersion != null && StringUtils.isNotEmpty( endVersion.getName()
) )
+            {
+                sb.append( endVersion.getName() );
+            }
 
-            cl.createArg().setValue( param );
+            cl.createArg().setValue( sb.toString() );
         }
 
         getLogger().info( "Executing: " + cl );



Mime
View raw message