(no subject)
Mar. 11th, 2004 12:10 pmI had a major moron moment this morning. I was wanting to change something on a website I run but I wanted to test it first. I had the best of intentions. So I went to the directory for this website, then got a directory list of the beta directory to see what needed to be replaced. Then, I decided to just delete everything in the beta directory and move the entire site over.
At this point I should note that I customized my linux prompt to look like this:
So I typed "rm ./*" which deleted every file in the web root. Luckily I didn't recursively delete it. I'm also lucky that the files for the site in that directory actually consisted of 5 files, the index and FAQ pages, 2 php scripts that got content for the pages from a database, and a stylesheet. Everything was recovered within 15 minutes, but I nearly gave myself a heart attack.
I also quickly enabled the feature to make the rm command ask for confirmation before deleting files.
At this point I should note that I customized my linux prompt to look like this:
[12:08 PM Thu Mar 11] [~] [yakko]$where [~] changes to whatever directory I'm in. So what I'm about to describe that I did...should have been avoided had I been paying attention. But alas...I wasn't.
So I typed "rm ./*" which deleted every file in the web root. Luckily I didn't recursively delete it. I'm also lucky that the files for the site in that directory actually consisted of 5 files, the index and FAQ pages, 2 php scripts that got content for the pages from a database, and a stylesheet. Everything was recovered within 15 minutes, but I nearly gave myself a heart attack.
I also quickly enabled the feature to make the rm command ask for confirmation before deleting files.