- Issue the following commands from the command line in your Yii application directory:
chmod +x psyii
mkdir extensions/yiishell
wget -O extensions/yiishell/psysh psysh.org/psysh
chmod +x extensions/yiishell/psysh
- Copy the file
init.php
below topsysh/init.php
and update any paths to work with your application configuration - Copy the file
config.php
below topsysh/config.php
. Change or add to the config array with the options you'd like to use (available options) - Now you can start PsySH with the command
./psyii psysh/init.php --config psysh/config.php
- Alternatively, for an easy way to start the shell, copy the
psyii
script below to your application directory, then run./shell
- Alternatively, for an easy way to start the shell, copy the
Based on article by mrdziuban for Yii1