Work on df
This commit is contained in:
parent
81dce313ad
commit
d3bae53bd7
3 changed files with 14 additions and 8 deletions
12
bin/php-swap
12
bin/php-swap
|
@ -1,12 +1,13 @@
|
|||
#!/usr/bin/bash
|
||||
line=$(php --version | grep "PHP" -m 1)
|
||||
libphp="/opt/lampp/modules/libphp7.1.so"
|
||||
case "$1" in
|
||||
5)
|
||||
file="/opt/lampp/etc/extra/httpd-xampp-php5.conf"
|
||||
phpexe=$(ls /opt/lampp/bin/php-5.6.*)
|
||||
phpcgi=$(ls /opt/lampp/bin/php-cgi-5.6.*)
|
||||
phpconfig=$(ls /opt/lampp/bin/php-config-5.6.*)
|
||||
phpize=$(ls /opt/lampp/bin/phpize-5.6.*)
|
||||
phpexe=$(ls /opt/lampp/bin/php-5.*)
|
||||
phpcgi=$(ls /opt/lampp/bin/php-cgi-5.*)
|
||||
phpconfig=$(ls /opt/lampp/bin/php-config-5.*)
|
||||
phpize=$(ls /opt/lampp/bin/phpize-5.*)
|
||||
;;
|
||||
7 | 7.1)
|
||||
file="/opt/lampp/etc/extra/httpd-xampp-php7.conf"
|
||||
|
@ -21,6 +22,7 @@ case "$1" in
|
|||
phpcgi=$(ls /opt/lampp/bin/php-cgi-7.0.*)
|
||||
phpconfig=$(ls /opt/lampp/bin/php-config-7.0.*)
|
||||
phpize=$(ls /opt/lampp/bin/phpize-7.0.*)
|
||||
libphp="/opt/lampp/modules/libphp7.0.so"
|
||||
;;
|
||||
*)
|
||||
echo "Please specify the version you want"
|
||||
|
@ -42,8 +44,8 @@ ln -s -f $phpexe /opt/lampp/bin/php
|
|||
ln -s -f $phpcgi /opt/lampp/bin/php-cgi
|
||||
ln -s -f $phpconfig /opt/lampp/bin/php-config
|
||||
ln -s -f $phpize /opt/lampp/bin/phpize
|
||||
ln -s -f $libphp /opt/lampp/modules/libphp7.so
|
||||
|
||||
# Also need to change /opt/lampp/modules/libphp7.so if 7.x.
|
||||
|
||||
$lampp startapache
|
||||
echo
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue