You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by hi...@apache.org on 2015/01/11 13:46:34 UTC
[1/2] ant-ivy git commit: Optimization: limit the revision numbers
scanned if revision prefix is specified
Repository: ant-ivy
Updated Branches:
refs/heads/master 6b2eba430 -> 3f9eb02b7
Optimization: limit the revision numbers scanned if revision prefix is
specified
Project: http://git-wip-us.apache.org/repos/asf/ant-ivy/repo
Commit: http://git-wip-us.apache.org/repos/asf/ant-ivy/commit/dc58a824
Tree: http://git-wip-us.apache.org/repos/asf/ant-ivy/tree/dc58a824
Diff: http://git-wip-us.apache.org/repos/asf/ant-ivy/diff/dc58a824
Branch: refs/heads/master
Commit: dc58a824466ed492fc6d5ab11960eb86584eff26
Parents: 6b2eba4
Author: Ernestas Vaiciukevicius <er...@gmail.com>
Authored: Fri Dec 26 14:22:23 2014 +0200
Committer: Nicolas Lalevée <ni...@hibnet.org>
Committed: Sun Jan 11 13:37:39 2015 +0100
----------------------------------------------------------------------
src/java/org/apache/ivy/ant/IvyBuildNumber.java | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/dc58a824/src/java/org/apache/ivy/ant/IvyBuildNumber.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/ivy/ant/IvyBuildNumber.java b/src/java/org/apache/ivy/ant/IvyBuildNumber.java
index 7f7ce7d..8634472 100644
--- a/src/java/org/apache/ivy/ant/IvyBuildNumber.java
+++ b/src/java/org/apache/ivy/ant/IvyBuildNumber.java
@@ -19,6 +19,7 @@ package org.apache.ivy.ant;
import java.util.List;
import java.util.ListIterator;
+import java.util.regex.Pattern;
import org.apache.ivy.Ivy;
import org.apache.ivy.core.module.id.ModuleId;
@@ -169,25 +170,32 @@ public class IvyBuildNumber extends IvyTask {
if (expression.equals(organisation) || expression.equals(module)
|| expression.equals(branch)) {
return exact.getMatcher(expression);
+ } else {
+ return regexp.getMatcher(expression);
}
- return regexp.getMatcher(expression);
}
public String getName() {
return "buildnumber-matcher";
}
};
+
+ String revisionPattern = ".*";
+ if (revision.endsWith("+")) {
+ revisionPattern = Pattern.quote(revision.substring(0, revision.length() - 1)) + ".*";
+ }
+
+ ModuleRevisionId mrid = ModuleRevisionId.newInstance(organisation, module, branch,
+ revisionPattern);
ModuleRevisionId[] revisions;
if (resolver == null) {
- revisions = searcher.listModules(
- ModuleRevisionId.newInstance(organisation, module, branch, ".*"), patternMatcher);
+ revisions = searcher.listModules(mrid, patternMatcher);
} else {
DependencyResolver depResolver = settings.getResolver(resolver);
if (depResolver == null) {
throw new BuildException("Unknown resolver: " + resolver);
}
- revisions = searcher.listModules(depResolver,
- ModuleRevisionId.newInstance(organisation, module, branch, ".*"), patternMatcher);
+ revisions = searcher.listModules(depResolver, mrid, patternMatcher);
}
ArtifactInfo[] infos = new ArtifactInfo[revisions.length];
[2/2] ant-ivy git commit: Update the release notes
Posted by hi...@apache.org.
Update the release notes
This closes #4
Project: http://git-wip-us.apache.org/repos/asf/ant-ivy/repo
Commit: http://git-wip-us.apache.org/repos/asf/ant-ivy/commit/3f9eb02b
Tree: http://git-wip-us.apache.org/repos/asf/ant-ivy/tree/3f9eb02b
Diff: http://git-wip-us.apache.org/repos/asf/ant-ivy/diff/3f9eb02b
Branch: refs/heads/master
Commit: 3f9eb02b76c31665b6ff44b11d4017f08065f4f3
Parents: dc58a82
Author: Nicolas Lalevée <ni...@hibnet.org>
Authored: Sun Jan 11 13:41:56 2015 +0100
Committer: Nicolas Lalevée <ni...@hibnet.org>
Committed: Sun Jan 11 13:41:56 2015 +0100
----------------------------------------------------------------------
doc/release-notes.html | 3 +++
1 file changed, 3 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ant-ivy/blob/3f9eb02b/doc/release-notes.html
----------------------------------------------------------------------
diff --git a/doc/release-notes.html b/doc/release-notes.html
index 4789072..babddfd 100644
--- a/doc/release-notes.html
+++ b/doc/release-notes.html
@@ -59,6 +59,8 @@ List of changes since Ivy 2.4.0:
- FIX: ArrayIndexOutOfBoundsException when using a p2 repository for dependencies (IVY-1504)
+- IMPROVEMENT: Optimization: limit the revision numbers scanned if revision prefix is specified (Thanks to Ernestas Vaiciukevičius)
+
- NEW: Lets ssh-based resolvers use an ~/.ssh/config file to find username/hostname/keyfile options (Thanks to Colin Stanfill)
<!-- Samples :
@@ -199,6 +201,7 @@ Here is the list of people who have contributed source code and documentation up
<li>Erwin Tratar</li>
<li>Jason Trump</li>
<li>David Turner</li>
+<li>Ernestas Vaiciukevičius</li>
<li>Tjeerd Verhagen</li>
<li>Richard Vowles</li>
<li>Sven Walter</li>