2 Sep
2001
2 Sep
'01
12:47
Hi everybody. I've made a backup script. It copies files from some certain directories to a backup one. Here is something i'd like to do but i don't know how i can start it : When i delete a file in source directories, i'd like that the script automatically delete it in backup. I tried something like that but it doesn't work very well for x in ( ls -R /home/charlie/ ); do ls /home/charlie/backup/$x &> /dev/null if [ $? != 0 ];then rm -r /home/charlie/backup/$x fi done I've a problem with the recursive part. I dont know how to had all subdirectories. thank you very much charlie ti