php 版本切换

php 版本切换

brew install homebrew/php/php-version.

细节:

Add the following to $HOME/.bashrc, $HOME/.zshrc, or your shell's equivalent configuration file:

  source $(brew --prefix php-version)/php-version.sh && php-version 5

It is recommended that you install versions of PHP via homebrew as depicted below:
  brew install php56
  brew unlink php56
Type `php-version --help` for more configuration options.

指令:

  • php -v


  • php-version / php-version
  • brew unlink 若安装冲突的时候运行

你可能感兴趣的:(php 版本切换)