summaryrefslogtreecommitdiff
path: root/get-m2.xml
diff options
context:
space:
mode:
authorMatthew Jason Benson <mbenson@apache.org>2006-06-23 22:41:47 +0000
committerMatthew Jason Benson <mbenson@apache.org>2006-06-23 22:41:47 +0000
commit3454a2bdc2d0a6a3d4941493b4b69ff9910e30f0 (patch)
treef38516b197206617581ba0a910c02023611ad5a8 /get-m2.xml
parentd6c1221db2a5545f574ce45a3f4932ab9ae9ca03 (diff)
downloadant-3454a2bdc2d0a6a3d4941493b4b69ff9910e30f0.tar.gz
Only DL if the _artifact_ was not found;
taskdef anytime the _antlib_ wasn't found. git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@416831 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'get-m2.xml')
-rw-r--r--get-m2.xml7
1 files changed, 4 insertions, 3 deletions
diff --git a/get-m2.xml b/get-m2.xml
index 6ded24743..af7feca67 100644
--- a/get-m2.xml
+++ b/get-m2.xml
@@ -58,9 +58,10 @@
<condition property="m2.antlib.typefound">
<typefound name="${m2.antlib.uri}:artifact" />
</condition>
+ <available property="m2.artifact.found" file="${m2.artifact}" type="file" />
</target>
- <target name="download-m2" depends="probe-m2" unless="m2.antlib.found">
+ <target name="download-m2" depends="probe-m2" unless="m2.artifact.found">
<require property="m2.antlib.url" />
<echo>Downloading to ${m2.dest.dir}</echo>
@@ -73,13 +74,13 @@
</target>
<target name="dont-validate-m2-checksum" depends="probe-m2"
- if="m2.antlib.found">
+ if="m2.artifact.found">
<property name="checksum.equal" value="true" />
</target>
<target name="validate-m2-checksum"
depends="download-m2,dont-validate-m2-checksum"
- if="m2.sha1.checksum" unless="m2.antlib.found">
+ if="m2.sha1.checksum" unless="m2.artifact.found">
<checksum file="${m2.artifact}"
algorithm="SHA"
property="${m2.sha1.checksum}"