PERL Resources

Started by wilnix, March 04, 2002, 03:32:28 PM

Previous topic - Next topic
What the hell are you thinking??? Of course I have Peksi here!!! It's one of the other food groups not recognized by Nutritionalists that man can not live with out! Along with beer... **in his best Homer voice** Mmmm... beeeeeer!

Got that too! :P
*** Sleep: A completely inadequate substitute for caffeine. ***
01010010010101000100011001001101

 :-\ I dont have any beer.

I always have peksi!

Wilnix
alt email address: wilnix@hackphreak.org

hahaha
"My Terminal is my Soul"

Wasn't this supposed to be about perl?

Wilnix
alt email address: wilnix@hackphreak.org

It still is!!! You can't code in perl unless you have a nice supply of peksi and/or beer!
*** Sleep: A completely inadequate substitute for caffeine. ***
01010010010101000100011001001101

Yuck I hate perl.

example - just to get yesterday's date (say you wanted it for archive filename purposes):

nautilus% more yest.pl
#!/usr/local/bin/perl
$yesterday = time() - (24 * 60 * 60 );
$thattime = (localtime $yesterday);
print "$thattime \n";

I put that together and keep it there in a file cos it's handy!

unfortunately you can't subtract one from the date with a math op or awk (won't work if it's the first day of the month!)so it has to be done this way :D

I avoid perl at all costs if possible. I can do almost anything I need to with a shell script - even if it is a bastardised way of doing it  ;)

That may be true, but running apache w/mod_perl sure makes for cool coding. Plus, I can buld some pretty quick scripts and stick them in crontab, ie (check for name services and restart, email admin if not running). Makes for not having to login at 2 AM...


Wilnix
alt email address: wilnix@hackphreak.org

SMF spam blocked by CleanTalk