#!/bin/bash # These are the formats I prefer seeing dates and times # -- altblue proper_date_format='%Y-%m-%d' proper_time_format='%H:%M:%S' ref_date='1970-04-01 20:09:08' epoch=$(date --date="$ref_date" +%s) dcmd="date --date=@$epoch" proper_date=$($dcmd "+$proper_date_format") proper_time=$($dcmd "+$proper_time_format") cat <