I’ve got log files that are created as log.2015-09-28T13-36-29
and I’m trying to change the names of the log files to better suit logrotate.
The following command works to display the file I need renamed:
ls log.$(date -d 'today' +'%Y-%m-%d')*
But this command gives me errors saying it can’t find the files.
mv "log.$(date -d 'today' +'%Y-%m-%d')*" "(date -d 'today' +'%Y-%m-%d').log"
Any ideas on how to fix this command? Or a better way to do it?