I wrote a simple script to backup of index.php and index.html in my box. So, I wrote a script which take a copy of the index page as 1Mar09: but it does not comes up..
#! /bin/bash
find . -name index.* > domains.txt
for i in `cat domains.txt` ; do cp index* index*.1Mar09 $i; done
But it gives a error message as :
cp: copying multiple files, but last argument `./kla/index.php' is not a directory
Try `cp --help' for more information.
cp: copying multiple files, but last argument `./kla/index.html' is not a directory
Try `cp --help' for more information.
cp: copying multiple files, but last argument `./n/index.php' is not a directory
Try `cp --help' for more information.
Please give a exact script and let me know where I am wrong?