aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOliver Schramm <oliver.schramm97@gmail.com>2016-08-04 04:29:01 +0200
committerOliver Schramm <oliver.schramm97@gmail.com>2016-08-04 04:29:01 +0200
commit6fd507f60db0f25c01818b9d6cd6d275672ce8c3 (patch)
tree3031da5b0fdebeabcd9f91d331d3cd7d9c7b58f7
parent5330ea0f0924ec8edff8522d340654617080e95e (diff)
downloadforums-6fd507f60db0f25c01818b9d6cd6d275672ce8c3.tar
forums-6fd507f60db0f25c01818b9d6cd6d275672ce8c3.tar.gz
forums-6fd507f60db0f25c01818b9d6cd6d275672ce8c3.tar.bz2
forums-6fd507f60db0f25c01818b9d6cd6d275672ce8c3.tar.xz
forums-6fd507f60db0f25c01818b9d6cd6d275672ce8c3.zip
[ticket/14731] Skip composer when exporting old versions
PHPBB3-14731
-rw-r--r--build/build.xml52
1 files changed, 29 insertions, 23 deletions
diff --git a/build/build.xml b/build/build.xml
index c412a747ac..2bece48edc 100644
--- a/build/build.xml
+++ b/build/build.xml
@@ -49,7 +49,7 @@
-->
<target name="composer">
<exec dir="phpBB"
- command="php ../composer.phar install --dev"
+ command="php ../composer.phar install"
checkreturn="true"
passthru="true" />
</target>
@@ -143,6 +143,7 @@
<phingcall target="export">
<property name="revision" value="release-${version}" />
<property name="dir" value="build/old_versions/release-${version}" />
+ <property name="skip-composer" value="true" />
</phingcall>
<phingcall target="clean-diff-dir">
@@ -251,26 +252,35 @@
<equals arg1="${composer-has-dependencies}" arg2="1" trim="true" />
<then>
<!-- We have non-dev composer dependencies -->
- <exec dir="."
- command="git ls-tree ${revision} composer.phar"
- checkreturn="true"
- outputProperty='composer-ls-tree-output' />
<if>
- <equals arg1="${composer-ls-tree-output}" arg2="" trim="true" />
+ <not><isset property="skip-composer" /></not>
<then>
- <fail message="There are composer dependencies, but composer.phar is missing." />
- </then>
- <else>
- <!-- Export the phar, install dependencies, delete phar. -->
<exec dir="."
- command="git archive ${revision} composer.phar | tar -xf - -C ${dir}"
- checkreturn="true" />
- <exec dir="${dir}"
- command="php composer.phar install --no-dev --optimize-autoloader"
+ command="git ls-tree ${revision} composer.phar"
checkreturn="true"
- passthru="true" />
- <delete file="${dir}/composer.phar" />
- </else>
+ outputProperty='composer-ls-tree-output' />
+ <if>
+ <equals arg1="${composer-ls-tree-output}" arg2="" trim="true" />
+ <then>
+ <fail message="There are composer dependencies, but composer.phar is missing." />
+ </then>
+ <else>
+ <!-- Export the phar, install dependencies, delete phar. -->
+ <exec dir="."
+ command="git archive ${revision} composer.phar | tar -xf - -C ${dir}"
+ checkreturn="true" />
+ <exec dir="${dir}"
+ command="php composer.phar install --no-dev --optimize-autoloader"
+ checkreturn="true"
+ passthru="true" />
+ <delete file="${dir}/composer.phar" />
+
+ <phingcall target="clean-vendor-dir">
+ <property name="dir" value="${dir}" />
+ </phingcall>
+ </else>
+ </if>
+ </then>
</if>
</then>
<else>
@@ -287,10 +297,6 @@
<delete dir="${dir}/develop" />
<delete dir="${dir}/install/data" />
- <phingcall target="clean-vendor-dir">
- <property name="dir" value="${dir}" />
- </phingcall>
-
<echo msg="Setting permissions for checkout of ${revision} in ${dir}" />
<!-- set permissions of all files to 644, directories to 755 -->
<exec dir="${dir}" command="find . -type f|xargs chmod 644" escape="false" />
@@ -307,6 +313,7 @@
<delete dir="${dir}/vendor/lusitanian/oauth/examples" />
<delete dir="${dir}/vendor/lusitanian/oauth/tests" />
<delete file="${dir}/vendor/lusitanian/oauth/.gitignore" />
+ <delete file="${dir}/vendor/lusitanian/oauth/.scrutinizer.yml" />
<delete file="${dir}/vendor/lusitanian/oauth/.travis.yml" />
<delete file="${dir}/vendor/lusitanian/oauth/phpunit.xml.dist" />
<delete file="${dir}/vendor/lusitanian/oauth/README.md" />
@@ -381,10 +388,9 @@
<delete file="${dir}/vendor/twig/twig/.editorconfig" />
<delete file="${dir}/vendor/twig/twig/.gitignore" />
<delete file="${dir}/vendor/twig/twig/.travis.yml" />
- <delete file="${dir}/vendor/twig/twig/AUTHORS" />
<delete file="${dir}/vendor/twig/twig/CHANGELOG" />
<delete file="${dir}/vendor/twig/twig/phpunit.xml.dist" />
- <delete file="${dir}/vendor/twig/twig/README.markdown" />
+ <delete file="${dir}/vendor/twig/twig/README.rst" />
</target>
<target name="clean-diff-dir">