diff options
author | Morris Jobke <hey@morrisjobke.de> | 2020-12-02 16:15:55 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-02 16:15:55 +0100 |
commit | 32f6bdf067ac877073af45b9170b042ebc0f790b (patch) | |
tree | e305c46dfce46ac838709f07378821c68b3b9d4a /build | |
parent | d69407963c68ac901ca950d956856aa99d24acf0 (diff) | |
parent | ef016f71c3554ca378f263300d4541ccc3f395b4 (diff) | |
download | nextcloud-server-32f6bdf067ac877073af45b9170b042ebc0f790b.tar.gz nextcloud-server-32f6bdf067ac877073af45b9170b042ebc0f790b.zip |
Merge pull request #24396 from nextcloud/dont-use-system-composer
dont use system composer for autoload checker
Diffstat (limited to 'build')
-rwxr-xr-x | build/autoloaderchecker.sh | 28 |
1 files changed, 11 insertions, 17 deletions
diff --git a/build/autoloaderchecker.sh b/build/autoloaderchecker.sh index ffa157f6c80..9bf8b17a8c9 100755 --- a/build/autoloaderchecker.sh +++ b/build/autoloaderchecker.sh @@ -1,26 +1,18 @@ #!/usr/bin/env bash -COMPOSER_COMMAND=$(which "composer") -if [ "$COMPOSER_COMMAND" = '' ] +COMPOSER_COMMAND="php composer.phar" + +if [ -e "composer.phar" ] then - #No global composer found, try local or download it - if [ -e "composer.phar" ] - then - echo "Composer found: checking for update" - else - echo "Composer not found: fetching" - php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" - php composer-setup.php - php -r "unlink('composer-setup.php');" - fi - - COMPOSER_COMMAND="php composer.phar" + echo "Composer found: checking for update" + $COMPOSER_COMMAND self-update else - echo "Global composer found: checking for update" + echo "Composer not found: fetching" + php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" + php composer-setup.php + php -r "unlink('composer-setup.php');" fi -#Make sure we are on the latest composer -$COMPOSER_COMMAND self-update REPODIR=`git rev-parse --show-toplevel` @@ -50,6 +42,8 @@ do fi done +rm composer.phar + echo if [ $composerfile = true ] then |