SUMMARY --> [Dub-pm] Time::Piece && while loops

Andrew Barnes andrew at
Fri May 7 06:13:52 CDT 2004


Thanks to everyone who replied!

In the end, I went with Time::Piece/Time::Seconds - was quite easy from
there.  At the end of my while loop, I run something along the lines of:

my $newDate = localtime;    #-# Get new current time/date

if ( $newDate->ymd > $currentDate->ymd ) {
    &handleHUP;             #-# Rotate the log
    our $currentDate = $newDate;

Thanks to my new-found knowledge of signals - I already had the code
written to rotate off the log file :-)

The real test will be when I try and change the date - but apart from that
- seems to be going well

Again - thanks!

Andrew Barnes
Computer Systems Consultant

Mobile: 087 3803633            | Intl Mobile: +353 87 3803633
Email:  andrew at
PGP Fingerprint: 2C8E E948 C62D 8C2C 48E3  0925 6ED3 78AA 5B17 6E26

More information about the Dublin-pm mailing list