newbie here.
(OT: Happy New Year, all.)
I placed a debugger statement into my ROR app and run ruby script/server webrick --debugger
My app hit the debugger statement.
I then did a var local
newbie here.
(OT: Happy New Year, all.)
I placed a debugger statement into my ROR app and run ruby script/server webrick --debugger
My app hit the debugger statement.
I then did a var local
newbie here.
(OT: Happy New Year, all.)
I placed a debugger statement into my ROR app and run ruby script/server webrick --debugger
My app hit the debugger statement.
[snip]
Since that was no better for me to understand, I tried (because I saw it somewhere) y @_response inside irb
I don't even see y documented as a debugger command.
It's not - it's a method that is part of the ruby standard library: it dumps the argument passed to it as yaml. It's mostly normal that this doesn't make any sense to you - it's exposing a lot of internal state from the response object. A good place to start would be to look at the api for the Response object and try the things you see there.
[snip]
That's a bit better but still mostly uninterpretable to me.
So ... how would I get programmatic access to, say, SERVER_NAME or the _session_id?
The debugger will run ruby code for you, so do exactly what you would do if you were writing code in that part of your app (eg if you're in a controller you could look at request.host or request.env
Is there documentation on how to use the debugger other than "help" or page 216 in the Pickaxe book?
just FYI, ruby-debug is not the same as the debugger described in the pickaxe
Fred