I know this isn’t strictly a Linux/Unix forum, but I hope someone here can help.
I’m wanting to extract the contents of a zip file. The contents are a single CSV file. The contents (the extracted CSV file) will be moved to a "data" folder.
I’ve got it working with the following command, but what I’m after is the ability to add a date/time to the filename. But how do I do this?
# The following does extract the contents, but never adds the date/time to the filename.
/usr/bin/unzip -a -o /path/to/inbound/traveldata.zip -d data/ > traveldata$(date +"%Y%m%d").csv
I hope someone can help.
Thanks