Linux : Setting which php bin to use in CLI -
hi i'm trying utilize php command in linux. have two installations of php, 1 got sudo-apt-get , 1 stack, lappstack. don't inquire how got there, nevertheless i'm trying execute php in cli .
$ php file.php
it both works whichever php points want utilize php utilize in stack.
when seek execute :
$ php
it returns :
/usr/bin/php
but have utilize php have in lappstack in :
/home/username/lappstack/php/bin
how alter php bin cli php points to?
you can replace php
in /usr/bin
yours this:
sudo rm /usr/bin/php sudo ln -s /home/username/lappstack/php/bin/php /usr/bin/php
hope helps
php linux command-line-interface bin
No comments:
Post a Comment