Browse Source

update codeigniter to use updated composer install

Lita Gratrix 10 years ago
parent
commit
9ba55ce86a
2 changed files with 15 additions and 9 deletions
  1. 13 7
      frameworks/PHP/codeigniter/install.sh
  2. 2 2
      toolset/setup/linux/systools/composer.sh

+ 13 - 7
frameworks/PHP/codeigniter/install.sh

@@ -1,13 +1,19 @@
 #!/bin/bash
 
-export PHP_HOME=${IROOT}/php-5.5.17
+RETCODE=$(fw_exists ${IROOT}/php-composer.installed)
+[ ! "$RETCODE" == 0 ] || { return 0; }
 
-export PHP_FPM=$PHP_HOME/sbin/php-fpm
+fw_depends php
 
-export NGINX_HOME=${IROOT}/nginx
+mkdir -p php-composer
+cd php-composer
 
-fw_depends php nginx composer
+fw_get https://getcomposer.org/installer -O composer-installer.php
 
-${PHP_HOME}/bin/php $IROOT/composer.phar install \
-  --no-interaction --working-dir $TROOT \
-  --no-progress --optimize-autoloader 
+# Use the PHP and composer from our PHP_HOME directory and 
+# COMPOSER_HOME directories (should be specified in frameworks 
+# install.sh file)
+${PHP_HOME}/bin/php composer-installer.php --install-dir=${COMPOSER_HOME}
+
+cd ..
+touch ${IROOT}/php-composer.installed

+ 2 - 2
toolset/setup/linux/systools/composer.sh

@@ -4,12 +4,12 @@ RETCODE=$(fw_exists ${IROOT}/php-composer.installed)
 [ ! "$RETCODE" == 0 ] || { return 0; }
 
 fw_depends php
-fw_get https://getcomposer.org/installer -O composer-installer.php
 
 mkdir -p php-composer
-
 cd php-composer
 
+fw_get https://getcomposer.org/installer -O composer-installer.php
+
 # Use the PHP and composer from our PHP_HOME directory and 
 # COMPOSER_HOME directories (should be specified in frameworks 
 # install.sh file)