On 11/30/2015 03:50 PM, Robert Moskowitz wrote:
Now I want to rename these files, which are all lectures to have the
date of creation/lastmodified in the file name.
Does the date require a specific format?
You could:
mv "$file" "$file-$(stat -c %y "$file")"
Or if you want to define your own (and assuming no file names contain
quote characters):
find $files -type f -printf 'mv "%p" "%p-%TY%Tm%Td"\n' | sh
--
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org