Install:
$ brew update && brew install composer
$ composer global require psy/psysh
# If asked what version constraint to use just type `*`
Update Your PATH
for global CLI use:
export PATH=~/.composer/vendor/bin:$PATH
Interactive Shell Use:
$ psysh
Debugger Use:
<?php
require('/Users/richardjortega/.composer/vendor/autoload.php');
# updated 'richardjortega' to your user name
# find path with `which psysh`
# some code is happening here
\Psy\Shell::debug(get_defined_vars());
# code stops line before with interactive shell!!!