I have a server running with the timezone set to
UTC. It seemed like that was generally a good practice (please correct me if I'm wrong).
Anyhow, one of the servers I connect to, in order to
scp files, is running on
EDT and stores files that I need to copy in the format
I looked at trying to
rsync files using something like find's
-mtime -1 flag for files modified in the last day, but I didn't have any luck.
I don't mind just using
scp to copy the current day's file, but as of right now there is a 4-hour window where running
date +%Y%m%d will give a different day on each server and that bugs me a little.
man date I see that I can have the time output as
UTC, but I don't see a way to have it output as another timezone like
I suppose I could also use something like the
GNU date extension
date -d 20100909 +%s to get the date in seconds from the epoch, apply a manual
4 * 60 * 60 second calculation, and see about rendering that as a date - but then when daylight time kicks in it will still be an hour off.
Is there a simpler way to output the date in a
YYYYMMDD format for
EDT on a server that is set to