I have the following in a shell script. How can I subtract one hour while retaining the formatting?
DATE=`date \"+%m/%d/%Y -%H:%M:%S\"`
if you need substract with timestamp :
timestamp=$(date +%s -d '1 hour ago');