Re: regex to convert 1000000 -> 1,000,000 ?
From: Sam Holden (sholden_at_flexal.cs.usyd.edu.au)
Date: 11/18/03
- Next message: Bigus: "Is there a quick way...."
- Previous message: Schlick: "Re: PERL array of arrays"
- In reply to: Wally Sanford: "Re: regex to convert 1000000 -> 1,000,000 ?"
- Next in thread: Abigail: "Re: regex to convert 1000000 -> 1,000,000 ?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 17 Nov 2003 23:38:09 GMT
On Mon, 17 Nov 2003 10:53:00 -0800,
Wally Sanford <wsanford@wallysanford.com> wrote:
> Sam Holden wrote:
>>
>> And one starts by reading the documentation for the language,
>> compiler, software package, whatever it is you are new to. For perl
>> the FAQ
>> is a big chunk of that documentation and pretty hard to miss, unless
>> of course you didn't bother looking at any of the documentation.
>
> Actually, the whole situation is like this: Perl is like a software
> package from a store that has a nice manual that under a hidden panel.
> you don't know it's there unless you KNOW it's there.
>
> Someone who is starting will likely not even of heard of "perldoc".
>
> If they are unixsavy they might try something like: $ perl --help | grep
> doc
> Which doesn not return anything. `$ perl --help` by it self does nothing
> to guide you to the docs.
A unixsavy person will type "man perl" which nicely lists all the other
man pages. inclusing perlfaq. A unixsavy person knows what:
"For ease of access, the Perl manual has been split up into several sections."
followed by a list of man page names means.
> Even grepping the man page for perl doesn't ofer much:
>
> $ man perl | grep doc
> perltoc Perl documentation table of contents
> perlpod Perl plain old documentation
> Extensive additional documentation for Perl modules is
> this additional documentation in the
> additional documentation is distributed standard with
> Perl, but you'll also find documentation for third-party
> You should be able to view Perl's documentation with your
Who greps manpages for "doc"? The manpage is the documentation. You
read it, and in the case of perl read the other pages it tells you
about.
>
> So a newbie might be inclined to try
>
> $ perltoc
> bash: perltoc: command not found
If the newbie is an idiot, and uses grep not to search and then check the
context, but to read.
A newbie needs to learn how to read documentation on their system before
they learn how to use perl.
>
> And `$ man perl | grep perldoc` return nothing, but the point is they
> have to first KNOW of perldoc.
perldoc is irrelevant, man works just fine and provides access to the
same documentation. Arguably better access due to the wonders of
man -k/apropos.
If someone uses unix and does not know about man, then they should stop
and learn about it *before* doing anything else with unix. Unix is
unusable without it.
>
> $ man perl | grep help
> you're not sure where you should look for help, try the -w
> Larry Wall <larry@wall.org>, with the help of oodles of
> help to others who wish to advocate the use of Perl in
> help mail in a bug report.
>
> This could bery well lead
>
> $ help perl
> bash: help: no help topics match `perl'. Try `help help'.
How does that random text lead to trying a "help" command. I see no
reference to such a command. How does it lead to "help perl" more than
it leads to "oodles perl" or "mail perl"?
>
> Many newsbies could of installed some linux distro that came with Perl
> and they decide on exploring it. Looking for documentation seems to be
> more then a trivial task.
>
> So, just short of going to www.perl.org, how is one suppost to know of
> perldoc and it's faq's off the bat?
man perl
man perlfaq
man perlfaq<relevant number>
> It's not a question of a newsgroup being like a coutry or whatever, but
> the lack of self advertising of perldoc it self. The fact thast there is
> no mention of it in the man page doing simple greps is unacceptable.
Again, perldoc is irrelevant. man works just fine. It is not the job of
the perl documentation to explain the use of man, that is the job of
"man man" :)
Do you want the perl documentation to include tutorial information on the
use of man, the use of the various microsoft help systems, the use of
a web browser to view HTMLized docs, etc, etc.
Assumming the reader can read documentation on the system they are using
is reasonable. How did they know to how to run perl otherwise? How did they
know how to create a file?
You could always of course upgrade to the current stable version of perl
which does in fact provide a reference to perldoc findable by your strange
"grep the man page for doc" approach to reading manpages:
; man perl | grep doc
Reformatting perl(1), please wait...
gate the rest of Perl's extensive documentation.
perltoc Perl documentation table of contents
perlpod Perl plain old documentation
perlpodspec Perl plain old documentation format specification
perldoc Look up Perl documentation in Pod format
tains the majority of the standard Perl documentation and the perldoc
Extensive additional documentation for Perl modules is available, both
You should be able to view Perl's documentation with your man(1) pro-
Complaining about things which have been fixed has no useful purpose.
>
> Expecting someone to of read documentation thats buried in a way that
> you didnt even know it was there in the "box" is what is unacceptable.
It isn't buried.
> Now that I think about it, I never even heard of perldoc until I first
> read this group a good some time ago.
So what, perldoc isn't important. It provides a nice way of specifying
perl documentation in this newsgroup, saying "perldoc perldata" is
nice since "man perldata" is meaningless on windows.
perldoc is nice for searching the FAQ (though not as nice as grep), but
you aren't meant to search the FAQ at the beginning, you are meant to
*read* it.
-- Sam Holden
- Next message: Bigus: "Is there a quick way...."
- Previous message: Schlick: "Re: PERL array of arrays"
- In reply to: Wally Sanford: "Re: regex to convert 1000000 -> 1,000,000 ?"
- Next in thread: Abigail: "Re: regex to convert 1000000 -> 1,000,000 ?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|