gwomacks / php-debug

Atom Text Editor package for PHP debugging
MIT License
119 stars 31 forks source link

Enable/Disable xdebug extension on demand #272

Open leandrogehlen opened 6 years ago

leandrogehlen commented 6 years ago

This allows better performance in development mode In debug panel in atom:

cchamplin commented 6 years ago

As in enable the extension inside PHP? I believe that would be out of scope for this project, as it requires a restart/rehash of PHP.

leandrogehlen commented 6 years ago

I really don’t known but it is possible in phpstorm https://blog.jetbrains.com/phpstorm/2016/06/xdebug-on-demand-for-cli-php-scripts-in-phpstorm-2016-2-eap/

leandrogehlen commented 6 years ago

If you create a configuration to define a script file that will be executed on open debug panel?

ghost commented 6 years ago

I think that @leandrogehlen talking about the functionality which was working before last update. Now when PHP Debug pane is closed and php code runs with exception, atom automatically opens the file and mark line where the exception has been occured. Before update the PHP Debug window have to be opened to mark exceptions.

So, It looks like the PHP Debug is working still in the bacground, because the Action Bar is also 'blinking' on screen (if no watchpoints, breakpoints marked and PHP Debug pane is closed).

cchamplin commented 6 years ago

@leandrogehlen and @appleandpear I've added a setting to stop listening when all the windows have been closed. Should be available in v0.3.4.

ghost commented 6 years ago

Thanks @cchamplin - works like a charm update: unfortunately it is working until the PHP Debug pane won't be open. After open and close it is still working in the background. Only restart Atom app is disabling this, but till the first PHP Debug pane open.