Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[MNG-3757] avoid deleting M2_HOME if it is empty

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@727671 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information...
commit 385888d545ba9c3f8fda9f0a0804790176a85926 1 parent e0cdbdc
@brettporter brettporter authored
Showing with 10 additions and 1 deletion.
  1. +10 −1 build.xml
View
11 build.xml
@@ -44,7 +44,16 @@ END SNIPPET: ant-bootstrap -->
<condition property="maven.home" value="${env.M2_HOME}">
<isset property="env.M2_HOME"/>
</condition>
- <fail unless="maven.home" message="You must set the M2_HOME environment variable or specify a maven.home property to this Ant script"/>
+ <fail message="You must set the M2_HOME environment variable or specify a maven.home property to this Ant script">
+ <condition>
+ <or>
+ <not>
+ <isset property="maven.home" />
+ </not>
+ <equals arg1="${maven.home}" arg2="" trim="true" />
+ </or>
+ </condition>
+ </fail>
</target>
<target name="init" depends="isMavenHomeSet">
Please sign in to comment.
Something went wrong with that request. Please try again.