Re: single step - debug mode

On 2/13/06, Bowen, Bruce <Bowenb@xxxxxxxxxxx> wrote:

I've read my Llama book and been out to goggle on this and while I've found data that
suggests it is possible to step thru a script file, I've yet to figure out the exact
command structure to accomplish this. I think it's -s arguments

Good try! But arguments after your program name ("" in this
case) are being passed to your program (via the @ARGV array), not
arguments to perl itself. And the flag argument that tells perl that
you want the debugger is -d. So you probably want something resembling
this command line, with the "arguments" being the ones passed to your
program, and the -d going to perl.

perl -d arguments

That will run your program under the debugger, so you should have a
debug prompt before the first executable statement runs. At that
point, you may use the 's' command to single-step through the code.
See the perldebug manpage for more, or use the 'h' command for help
while running the debugger.

Hope this helps!

--Tom Phoenix
Stonehenge Perl Training

Relevant Pages

  • Re: Wait for background processes to complete
    ... To be able to execute commands in the background and wait for their ... The documentation I am referring to is ... You can run a command in the background with: ... There is a general problem with perl documentation: ...
  • Re: Perl For Amateur Computer Programmers
    ... >professional computer programmers could use with the same ease as Basic. ... >Perl For Amateur Computer Programmers ... Also, taking into account that you're appealing to "scientists", it ... Also, as a side note, you seem to use the noun "command" in a naive ...
  • Obtaining complete Unix command line that evoked script as string
    ... If there is a more appropriate list for this, let me know; the other perl lists I've seen seem to specialised for this. ... Note this is not just the arguments of the call to the script, but everything including pipes and redirects, etc., e.g. ... Ideally the perl interpreter would grab the complete command line as its evoked and I'd access this via a variable. ...
  • Re: CLOSING Re: Obtaining complete Unix command line that evoked script as string
    ... > To: Grant Jacobs; beginners perl ... > perl and less, much less passing that information along to either ... Only shell that launched them is keeping track of the I/O ... > command is executed. ...
  • Thanks for the comments Jan. 25, 2006
    ... "shadow" operating system which is running behind Windows. ... Perl can then collect data from that program and do ... that by sending longer strings etc. to the Windows clipboard and then having ... SendKeysuse a Ctrl V command to paste the information to the text editor ...