Menu

$PATH modification

Christian Weiske

To make phpfarm-compiled php versions globally available, you need to modify your $PATH variable. The best is to put a script into /etc/profile.d/:

$ cat /etc/profile.d/phpfarm.sh 
#!/bin/sh
PATH=$PATH:/opt/phpfarm/inst/bin:/opt/phpfarm/inst/current-bin

This will still give the system-installed php version precedence. If you want to have the PHP version set by switch-php, put current-bin before the old $PATH:

$ cat /etc/profile.d/phpfarm.sh 
#!/bin/sh
PATH=/opt/phpfarm/inst/bin:/opt/phpfarm/inst/current-bin:$PATH

Do not forget to make the script executable.

Now every user will have the modified $PATH variable.


Related

Wiki: Home

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.