Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I set a breakpoint inside of atom's package?

I am trying to figure out why this atom package https://github.com/AtomLinter/linter-elixirc/ misbehaves. Its author said I should set a breakpoint in some function of the package to see what's going on there. I have no idea how to do that while running atom.

Here is the comment I am talking about: https://github.com/AtomLinter/linter-elixirc/issues/63#issuecomment-214916262

like image 603
CrabMan Avatar asked May 01 '16 07:05

CrabMan


People also ask

How do you insert a breakpoint in an atom?

How do you use it? Pressing F9 will toggle a breakpoint on the current line. The breakpoints will be saved in (Project root)/. breakpoints by default in a format that gdb can use with the command line argument -x .

Where do you put a breakpoint?

To set a breakpoint in source code: Click in the far left margin next to a line of code. You can also select the line and press F9, select Debug > Toggle Breakpoint, or right-click and select Breakpoint > Insert breakpoint. The breakpoint appears as a red dot in the left margin.

Can I Debug in atom?

Open the debug view by pressing ctrl+alt+d , selecting 'Toggle Debugging' from the Command Palette or php-debug menu. Start the script with Xdebug enabled. If everything is setup correctly, the entire line of the breakpoint will be highlighted in green, indicating the current line of the script.


1 Answers

When you're in Atom, hitting Ctrl+Alt+I (or View -> Developer -> Toggle Developer Tools) will open developer tools. If you know Chrome dev tools, it looks the same. Then just navigate to sources, find your package and set breakpoints. From menu go to view -> Developer -> reload window (or Alt + Ctrl + R) to re-run, so program can hit those breakpoints.

like image 113
kasperoo Avatar answered Oct 07 '22 14:10

kasperoo