Sunday, July 11, 2010

Previous date in BASH script?

I have a statement in a Linux BASH shell script that reads: DATE=$(date +"%Y%m%d-%H%M" ) which gets current date/time.. but I need to modify it so it creates a date string from 5 days ago (current time is fine). I can't find how to do this.

Previous date in BASH script?
Check out the -d option in date:


http://www.cyberciti.biz/tips/linux-unix...


No comments:

Post a Comment