Script to append date stamp to Microsoft Office Word file on Linux:
#!/bin/sh
file_name=test_files.docx
current_time=$(date "+%Y.%m.%d-%H.%M.%S")
echo "Current Time : $current_time"
new_fileName=$file_name.$current_time
echo "New FileName: " "$new_fileName"
cp $file_name $new_fileName
echo "You should see new file generated with timestamp on it.."
-----------------------
Bill Gates
"Measuring programming progress by lines of code is like measuring aircraft building progress by weight"
[]
#!/bin/sh
file_name=test_files.docx
current_time=$(date "+%Y.%m.%d-%H.%M.%S")
echo "Current Time : $current_time"
new_fileName=$file_name.$current_time
echo "New FileName: " "$new_fileName"
cp $file_name $new_fileName
echo "You should see new file generated with timestamp on it.."
-----------------------
Bill Gates
"Measuring programming progress by lines of code is like measuring aircraft building progress by weight"
[]
No comments:
Post a Comment
Коментар: