1
0
mirror of synced 2025-01-18 17:01:41 +03:00

Fix problem with composer. Use composer version 1.10.17

This commit is contained in:
Dima Uryvskiy 2020-11-19 10:51:49 +03:00 committed by GitHub
parent e7dc2343f4
commit 222a90d755
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 8 deletions

View File

@ -75,6 +75,7 @@ install_woocommerce() {
cd /tmp cd /tmp
git clone https://github.com/woocommerce/woocommerce.git git clone https://github.com/woocommerce/woocommerce.git
cd woocommerce cd woocommerce
php -r "copy('https://getcomposer.org/download/1.10.17/composer.phar', 'composer.phar');"
if [[ ! $WC_VERSION == 'latest' ]]; then if [[ ! $WC_VERSION == 'latest' ]]; then
# If we use php 5.3, we have problem with warning: CRLF will be replaced by LF in tests/legacy/unit-tests/importer/sample_update_product.csv. # If we use php 5.3, we have problem with warning: CRLF will be replaced by LF in tests/legacy/unit-tests/importer/sample_update_product.csv.
@ -87,14 +88,14 @@ install_woocommerce() {
version=($(echo $WC_VERSION | tr "." "\n")) version=($(echo $WC_VERSION | tr "." "\n"))
if [[ ${version[0]} -ge 3 && ${version[1]} -ge 7 ]]; then if [[ ${version[0]} -ge 3 && ${version[1]} -ge 7 ]]; then
composer install php composer.phar install --ignore-platform-reqs
# npm install
fi fi
fi fi
if [[ $WC_VERSION == 'latest' ]]; then if [[ $WC_VERSION == 'latest' ]]; then
composer install php composer.phar install --ignore-platform-reqs
# npm install php composer.phar dump-autoload
php composer.phar update
fi fi
cd - cd -