maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdca...@apache.org
Subject svn commit: r806388 - in /maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering: AbstractMavenFilteringRequest.java DefaultMavenFileFilter.java
Date Thu, 20 Aug 2009 22:50:46 GMT
Author: jdcasey
Date: Thu Aug 20 22:50:46 2009
New Revision: 806388

URL: http://svn.apache.org/viewvc?rev=806388&view=rev
Log:
simplify default delimiters spec, and fix a small logical error in handling delimiterSpec
splitting.

Modified:
    maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/AbstractMavenFilteringRequest.java
    maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/DefaultMavenFileFilter.java

Modified: maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/AbstractMavenFilteringRequest.java
URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/AbstractMavenFilteringRequest.java?rev=806388&r1=806387&r2=806388&view=diff
==============================================================================
--- maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/AbstractMavenFilteringRequest.java
(original)
+++ maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/AbstractMavenFilteringRequest.java
Thu Aug 20 22:50:46 2009
@@ -93,7 +93,7 @@
         projectStartExpressions.add( "project" );
         
         delimiters.add( "${*}" );
-        delimiters.add( "@*@" );
+        delimiters.add( "@" );
     }
 
     public MavenProject getMavenProject()

Modified: maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/DefaultMavenFileFilter.java
URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/DefaultMavenFileFilter.java?rev=806388&r1=806387&r2=806388&view=diff
==============================================================================
--- maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/DefaultMavenFileFilter.java
(original)
+++ maven/shared/trunk/maven-filtering/src/main/java/org/apache/maven/shared/filtering/DefaultMavenFileFilter.java
Thu Aug 20 22:50:46 2009
@@ -238,10 +238,15 @@
                 final String[] delimiters = new String[2];
                 
                 int splitIdx = delimiterPattern.indexOf( '*' );
-                if ( splitIdx < 0 || splitIdx == delimiterPattern.length() - 1 )
+                if ( splitIdx < 0 )
                 {
                     delimiters[0] = delimiterPattern;
-                    delimiters[1] = delimiterPattern;
+                    delimiters[1] = delimiters[0];
+                }
+                else if ( splitIdx == delimiterPattern.length() - 1 )
+                {
+                    delimiters[0] = delimiterPattern.substring( 0, delimiterPattern.length()
- 1 );
+                    delimiters[1] = delimiters[0];
                 }
                 else
                 {



Mime
View raw message