command-line debugging with PHPStorm

I'm unable to get command-line debugging working with PHPStorm.

Here's my setup:

Running PHPStorm on Mac OS X/Snow Leopard.

We have a remote development server where all of my files and PHP server lives.

I am mounting these files over AFP.

I have set up a "PHP on Server" debug configuration, and checked "Wait for XDebug connection with IDE key:". I've tried a number of things as the IDE key, currently I have "PhpStorm2".

On the server, I want to run some unit tests using phpunit.

We have a "wrapper" file that executes our tests. Before launching that, I set some php env vars using the following alias:

alias phpdebug='php -c ~/php.ini'

In ~/php.ini, I have:

xdebug.remote_autostart=1
xdebug.remote_enable=1
xdebug.remote_host=172.16.11.169
xdebug.remote_port=9169
xdebug.idekey=PhpStorm2



So when I run my tests, I do:

phpdebug ./icpunit [test name]

This all works great with Eclipse. I set up Eclipse to prompt whenever it notices an XDebug session request, and it automatically starts up a debug session.

I don't see this option in PHPStorm, so I assume I have to manually start the debug session. When I do this, I see the message "Waiting for connection on port 9169 with ide key 'PhpStorm2'", but when I run my tests, no connection is made, no breakpoints are hit.

This all works fine in NetBeans as well, BTW.

This is a "dealbreaker" feature for me. If it doesn't work I will go back to either Eclipse or NetBeans... which would make me sad, because I love PHPStorm's editor!

Please sign in to leave a comment.