The use-case is the following: You debug a script and inspect a large data-structure via x $huge_reference.
Unfortunately this is really big and you would like to inspect it more closely in an editor, so you need to dump the structure into a file...
This is how to do it in the debugger:
First set up a pager like this: o pager=">my_file"
Then pipe the x-command through the pager like this: |x $huge_reference
That's it - "my_file" now contains the dump for you to inspect.
You can even set up a pager as ">>my_file" for appending.
I apologize for setting this up as a meditation as it may be common knowledge among Perl-hackers but it was new to me and I hope it might be useful for someone else as well.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: output to a file from the debugger
by iamsolarplexus (Initiate) on Mar 31, 2016 at 20:56 UTC | |
|
Re: output to a file from the debugger
by Anonymous Monk on Jan 14, 2014 at 20:27 UTC | |
by Anonymous Monk on Sep 05, 2014 at 01:53 UTC | |
|
Re: output to a file from the debugger
by Anonymous Monk on Jul 25, 2012 at 02:49 UTC |