#! /bin/bash # # Toomas Karmo # http://www.metascientia.com # # # invocation: # ./b filename (on the assumption that the script is named b) # # # given filename foo.bar, # create a backup copy foo.bar_CCYYMMDDThhmmssZ, # where CCYYMMDDThhmmssZ is current Coordinated Universal Time # timestamp # cp $1 ${1}____BAK$(date -u "+%Y%m%dT%H%M%SZ") ls -1 ${1}*