[plug] I hate myself :( rm -r gone too far....

Trent Lloyd trent at ucc.gu.uwa.edu.au
Thu Aug 22 12:53:41 WST 2002


ummm
some bash script
if file_exists or something

i think move wont overwrite by default
or im sure that cp has a no-overwrite function


On Thu, Aug 22, 2002 at 12:47:43PM +0800, Sol wrote:
> I wanted to destroy a no longer needed configuration 
> directory /usr/local/etc/ .  A careless moment of stupidity caused me 
> to do this:
> 
> localhost:/usr/local# rm -r /etc
> 
> Fortunately I ctrl-c after about 2 seconds and stopped this command 
> from reaching it's completion. It seems on the surface that not much is 
> lost. I have /etc backed up from about one month ago and most of it 
> should be current. However, I don't want to just copy the backup over 
> the damaged directory because I will lose whatever configuration I've 
> done in the past month.
> 
> My question is after I unpack etc.tgz, how can I work out the 
> differences between the files in the two directories so that I know 
> which files need to be replaced?
> 
> Thankyou.
> sol
> 

-- 
Trent Lloyd [Lathiat]

http://www.linux.conf.au/ - Jan 22-25 2003
  Australian Linux Technical Conference



More information about the plug mailing list