Enable Phpstorm Xdebug listening:
$ export XDEBUG_CONFIG="idekey=PHPSTORM"
Press the listen button inside Phpstorm to actually listen:
To disable Phpstorm Xdebug processing in Bash again:
$ unset XDEBUG_CONFIG
This (PHPSTORM) is the default Phpstorm IDE-Key. You don’t need to disable listening after the variable is unset.
Should work with any other UNIXoide shell as well.
See as well: