in reply to compress logs based on date and copy to local windows machine
Beware of assuming that all days have 24 hours. Since you are using the localtime() function, most days will have 24 hours as expected, but some days will have 25 hours (autumn DST change), and some days will have 23 hours (spring DST change). This little oversight bit me in back side last year.
If you run your script just after midnight, your date calculation will be an entire day off when it runs on the morning following the fall DST change.
|
|---|