Note: This expects that you've enabled Xdebug in a specific file: /usr/local/php/X.x/conf.d/ext-xdebug.ini.
Add this function to your .zshrc or similar file.
On the command line, type xdebug and hit enter. This will toggle whether or not Xdebug is running.