I was playing aroudn with some variations of date like
DATE = $(date)
but that didnt work either
crontab -e
CRONLOG=/tmp/log/crontab.log
DATEVAR=`date +20\%y\%m\%d_\%H\%M\%S`
* * * * * echo $DATEVAR >> /tmp/log/crontab.log
*/2 * * * * echo "$DATEVAR hello" >> ${CRONLOG}
*/1 * * * * echo 'every minute' >> ${CRONLOG}
this just outputs the text as is...
I want to create a log entry in crontab.log with a timestamp on each update
How can I do this on CentOS 6?
UPDATE
DATEVAR=date +20%y%m%d_%H%M%S
*/1 * * * * /bin/echo [CRON] $($(DATEVAR)) >> /tmp/log/crontab.log
rendered only [CRON] and NOTHING when I tried it =/