Do not overwrite dist/*.phar files v0.5.0
authorChristian Weiske <cweiske@cweiske.de>
Mon, 28 Aug 2017 15:17:45 +0000 (17:17 +0200)
committerChristian Weiske <cweiske@cweiske.de>
Mon, 28 Aug 2017 15:17:45 +0000 (17:17 +0200)
build.xml

index 12a01f3..c57735d 100644 (file)
--- a/build.xml
+++ b/build.xml
   </copy>
 
   <mkdir dir="${phing.dir}/dist"/>
-  <!-- <delete file="${pharfile}"/> -->
+
+  <available file="${pharfile}" property="phar_exists" value="1"/>
+  <fail if="phar_exists" message="File exists already: ${pharfile}"/>
+
   <pharpackage basedir="${phing.dir}"
    destfile="${pharfile}"
    stub="${phing.dir}/src/phar-stub.php"