What? You didn't complain that they didn't list Perl? Well
I was curious and dug up the following interesting reading
in a few minutes. I feel that there should be earlier mention but
it eluded me. No matter, these are still worth looking at:
- In a thread on what motivates a programmer, Larry
mentions Perl
and the now-famous quote "The two chief virtues in a programmer are laziness and impatience." This was in
the pre-hubris days of course.
- later in that same thread Larry is forced to give a description
of Perl (with some examples) when someone asks "So what is this program 'perl'?"
- Finally the first public distribution
of Perl 1.0 (1988-02-01 05:46:32 PST). Just seeing code in multi-part shars was a real trip down memory lane for me... I wonder if
something like that would meet their significance threshold for inclusion in their timeline?
I most want to find the actual exchange in which Andy Tanenbaum tells Linus Torvalds that he'd have
failed him (had Linus been in Andy's OS class, or country even) during a debate on the pros and cons of monolithic kernels, but
so far I've only seen a reference to the posting.
Update: Thanks ar0n! Here is the actual posting in which AST tells Linus
Be thankful you are not my student. You would not
get a high grade for such a design :-)
- he even includes a smiley. It is fascinating to re-read the exchange now, as the current hero Linus comes of as snot-nosed (albeit with some good thinking), and AST as the gracious wise man. I was
unable to find this because I felt certain that AST had used the word "fail", but now I see that he was not so harsh.
Update 2: Yes I noticed that good one jmerelo but I didn't list it as it didn't describe Perl much. Another one I ran across was this which is not much later and the .sig comment perhaps shows just how popular Perl had become in a short time. BTW some may recall Mark Biggar being referred to as "Perl's maternal uncle" for many years.
--
I'd like to be able to assign to an luser | [reply] |
So I got to looking at the first perl node that you mention... what an incredibly interesting piece of history! Larry pretty much had the right idea all along :) I however especially like his sample code:
#!/bin/perl
$SIG{'QUIT'} = 'quit'; # install signal handler for SIGQUIT
while ($ARGV[0] =~ /^-/) { # parse switches
$ARGV[0] =~ /^-h/ && ($showhost++,$silent++,shift,next);
$ARGV[0] =~ /^-s/ && ($silent++,shift,next);
$ARGV[0] =~ /^-d/ && ($dodist++,shift,next);
$ARGV[0] =~ /^-n/ && ($n=' -n',shift,next);
$ARGV[0] =~ /^-l/ && ($l=' -l ' . $ARGV[1],shift,shift,next);
last;
}
$systype = shift; # get name representing set of hosts
while ($ARGV[0] =~ /^-/) { # we allow switches afterwards too
$ARGV[0] =~ /^-h/ && ($showhost++,$silent++,shift,next);
$ARGV[0] =~ /^-s/ && ($silent++,shift,next);
$ARGV[0] =~ /^-d/ && ($dodist++,shift,next);
$ARGV[0] =~ /^-n/ && ($n=' -n',shift,next);
$ARGV[0] =~ /^-l/ && ($l=' -l ' . $ARGV[1],shift,shift,next);
last;
}
if ($dodist) { # distribute input over all rshes?
`cat >/tmp/gsh$$`; # get input into a handy place
$dist = " </tmp/gsh$$"; # each rsh takes input from there
}
$cmd = join(' ',@ARGV); # remaining args constitute the com
+mand
$cmd =~ s/'/'"'"'/g; # quote any embedded single quotes
open(ghosts, '/etc/ghosts') || die 'No /etc/ghosts file';
# /etc/ghosts drives the rest
$one_of_these = ":$systype:"; # prepare to expand "macros"
if ($systype =~ s/\+/[+]/g) { # we hope to end up with list of
$one_of_these =~ s/\+/:/g; # colon separated attributes
}
line: while (<ghosts>) { # for each line of ghosts
s/[ \t]*\n//; # trim leading whitespace
if (!$_ || /^#/) { # skip blank line or comment
next line;
}
if (/^([a-zA-Z_0-9]+)=(.+)/) { # a macro line?
$name = $1; $repl = $2;
$repl =~ s/\+/:/g;
$one_of_these =~ s/:$name:/:$repl:/; # do expansion in "wanted"
+ list
next line;
}
# we have a normal line
@attr = split; # a list of attributes to match against
# which we put into an array
$host = $attr[0]; # the first attribute is the host nam
+e
if ($showhost) {
$showhost = "$host:\t";
}
attr: while ($attr = pop(attr)) { # iterate over gh arr
+ay
if (index($one_of_these,":$attr:") >=0) { # is host wanted?
unless ($silent) { print "rsh $host$l$n '$cmd'\n"; }
$SIG{'INT'} = 'DEFAULT';
if (open(pipe,"rsh $host$l$n '$cmd'$dist |")) { # start rsh
$SIG{'INT'} = 'cont';
while (<pipe>) { print $showhost,$_; } # show results
close(pipe);
} else {
$SIG{'INT'} = 'cont';
print "(Can't execute rsh.)\n";
}
last attr; # don't select host twice
}
}
}
unlink "/tmp/gsh$$" if $dodist;
# here are a couple of subroutines that serve as signal handlers
sub cont {
print "\rContinuing...\n";
}
sub quit {
$| = 1;
print "\r";
$SIG{'INT'} = '';
kill 2, $$;
}
:) I think it'd be fun to translate that to perl 5 (or 6 even) and use all of the new tools... funny thing is, that code would be chastized on perlmonks like crazy... no strict, no -w, handrolled commandline parsing! tsk tsk tsk. (I know that Perl back then didn't have these things, my sarcasm flag is set to 1 :) Also, a very interesting little historical sidenote:
I wasn't going to add a "goto" except that the sed-to-perl translator needed one. :) how fun is that! Also of note: On top of which, C didn't have the picture-style report formats I wanted. And I didn't want to do a make every time I tweaked the program. I take it he is talking about perl formats... a feature that has now been voted out of the core and into a module (if memory serves me right...) So, I guess that says a few things about how perl has moved from a systems management / formatting language to a much more general beast. I guess he succeeded when he said he wanted to make a language that is: intended to be practical (easy to use, efficient, complete) rather than beautiful (tiny, elegant, minimal).
| [reply] [d/l] |
| [reply] |
Actually, the first Perl mention seems to be this one
Faigin, Larry's coworker, mentions Perl as Larry's "3-month old child", together
with his real and "programatic children"
| [reply] |
| [reply] |
| [reply] |
| [reply] |
| [reply] |
| [reply] |
Damn, this post is 18 days older than me.
I've missed soo much :-(
--
package Lizard::King;
sub can { do { 'anything'} };
| [reply] [d/l] |
| [reply] |
I can't really imagine waiting until 1997 to see all nine parts of the Star Wars series.
The horror of hindsight.
----Asim, known to some as Woodrow.
| [reply] |