Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: RFC: How to survive your first few months of Perl

by kyle (Abbot)
on Nov 11, 2008 at 15:28 UTC ( #722872=note: print w/replies, xml ) Need Help??


in reply to RFC: How to survive your first few months of Perl

  1. Use strict and warnings!
  2. diagnostics
  3. perldoc -f
  4. YAPE::Regex::Explain
  5. perl -MO=Deparse and perl -MO=Deparse,p (B::Deparse)
  6. perldoc -l Some::Module | xargs less

Replies are listed 'Best First'.
Re^2: RFC: How to survive your first few months of Perl
by graff (Chancellor) on Nov 12, 2008 at 02:48 UTC
    perldoc -f

    In my first few months of using Perl (back in 1995), I cannot tell you how much time I would have saved if I had known about this option on perldoc. Initially, I was learning by adapting code that someone else had written, so in the course of a day, I ran "perldoc perlfunc" repeatedly to look up the details on function calls, and I was constantly paging down to the function of interest...

    UPDATE: On second thought, I have to admit that I learned a lot more about perl (and grew to appreciate it more quickly) by virtue of spending so much time with the "perlfunc" man page.

Re^2: RFC: How to survive your first few months of Perl
by MidLifeXis (Monsignor) on Nov 11, 2008 at 16:44 UTC
    perldoc -l Some::Module | xargs less

    How about perldoc -m Some::Module instead?

    --MidLifeXis

      If you define PERLDOC_PAGER=less or PAGER=less in your environment, say in .bashrc or the equivalent, it works fine. Otherwise perldoc will use more as a pager, which works, but doesn't know how to scroll backwards. That's sad.

        It all depends on your unix environment / version of more. HP-UX more handles paging backwards just fine, for example. I would agree that not being able to page backwards is a pain, but it is not a generic more problem, but rather a problem with the more program on specific distributions.

        --MidLifeXis

Re^2: RFC: How to survive your first few months of Perl
by cog (Parson) on Nov 12, 2008 at 10:58 UTC
    Use strict and warnings!

    Doh! I was missing the obvious :-)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://722872]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (None)
    As of 2021-10-20 01:57 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?
      My first memorable Perl project was:







      Results (78 votes). Check out past polls.

      Notices?