Home >Backend Development >PHP Tutorial >How to solve the problem of changing php version and -bash command on mac
版Mac PHP version changes, such as php7.0.0 mamp
vi
.bash_profile
export Path = "/Applications/MAMP/BIN/PHP/PHP7.0.0/Bin: $ PATH"
. .
bash_profile-bash command failure repair method
For example:
-bash: ls :command not found
step1.
Enter in the terminal:
export PATH="/usr/ bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin"
Then the command can be used temporarily,
step2.
Hurry up and use open -e ~/. bash_profile Open the .bash_profile file in a text editor:
step3.
Change the PATH environment variable setting and add this line,
export PATH="/usr/bin:/bin:/usr/sbin:/sbin :/usr/local/bin:/usr/X11/bin"Then save it and there will be no problem.