php --ini
- install
psysh
composer g require psy/psysh:@stable
ln -s ~/.composer/vendor/bin/psysh /usr/local/bin/psysh
psysh
- add php manual https://github.com/bobthecow/psysh/wiki/PHP-manual
download the
php_manual.sqlite
and copy file to~/.local/share/psysh/
sudo apt-get install -y php7.1 php7.1-fpm php7.1-cli php7.1-common php7.1-mbstring php7.1-gd php7.1-intl php7.1-xml php7.1-mysql php7.1-mcrypt php7.1-zip
more read on mac OS php71 became php71 with brew
# Reinstall PHP 7.1
brew reinstall php@7.1
# check carefully that overwriting links won't break things
brew link --overwrite --force --dry-run php@7.1
# Run it for real this time assuming you checked
brew link --overwrite --force php@7.1
# Double check that you are now using homebrew's PHP
which php
# This should identify any missing extensions
php -v
# Reinstall missing extensions. In my case:
brew reinstall php71-xdebug php71-imagick
# Check that php can find the extension.
php -v
$ curl -L https://gist.githubusercontent.com/rhukster/f4c04f1bf59e0b74e335ee5d186a98e2/raw > /usr/local/bin/sphp
$ chmod +x /usr/local/bin/sphp
$ sphp 7.1