hello,
can anyone tell me how to rename a filename in a script to contain the current date?
i have searched for the answer but with little success!
many thanks
rkap
hello,
can anyone tell me how to rename a filename in a script to contain the current date?
i have searched for the answer but with little success!
many thanks
rkap
what is your desired filename format?
Just a quick example. I use a script 'note' to just keep some random notes in the filesystem:
Cheers,
Keith
#!/bin/ksh
dateFormat=`date +%m%d%y`
finalFileName="$inputFileName$dateFormat.log" #if u want to add an extension
#Move the Processed File
/usr/bin/mv ~/$inputFileName ~/$finalInputFileName
much appreciated.....