1

I'm new to rails. The current way that I do debug on rails is:

  1. Run rails in rubymine in debug mode
  2. Instead of putting a break point, I will put down "binding pry" in code
  3. Open terminal and type "rails c".
  4. Trigger the specific state/event in terminal so I can get to the break point.

This is not my preferred workflow. It is tedious. I really like jet brain's debug mode when I can easily put down a break point, stop, evaluate expressions, look up all available objects, and step into a specific method. Is there anyway to do this with rails?

user3019766
  • 131
  • 1
  • 10
  • Why aren't you putting the breakpoint down, again? – Makoto Jan 29 '16 at 23:25
  • so you can debug? when you put down break point, your program will stop at a specific line so you can inspect all objects. – user3019766 Jan 30 '16 at 01:13
  • Yes. That's the point of the debugger. Why *aren't* you putting the break point down? – Makoto Jan 30 '16 at 01:28
  • Apologies for able to understand your question. "put down break points" means I'm setting the breakpoint mark on my IDE next to line of code so I before running that line, i would be able to enter debug mode and inspect all objects. I did put down break point, but in order to reach to those break points, I would have to trigger in terminal to trigger certain events. But when these events are being triggered, the break points doesn't break. – user3019766 Jan 30 '16 at 01:40
  • Clarify this in your question then - it legitimately tripped me up when you said, "Instead of putting a break point...". – Makoto Jan 30 '16 at 02:27
  • That is my current work flow tho? – user3019766 Feb 01 '16 at 18:02

1 Answers1

5

So eventually I figured this out. Tools->Run Rails Console

user3019766
  • 131
  • 1
  • 10