This post originated from an RSS feed registered with Ruby Buzz
by Robby Russell.
Original Post: oops, didn't mean to rake that
Feed Title: Robby on Rails
Feed URL: http://www.contegix.com/rss/feed.xml
Feed Description: My reflections on programming with Ruby, Rails, PostgreSQL... and learning how to run a business...
I accidental caused typo to delete everything. I switched to production and it wasn't working, ran rake and (had used the same db name) and goodbye 63 entries.
A backup! Woo... untar my pg_dump file... nothing there. Apparently, I was running the wrong version of pg_dump against the postgresql version for my typo blog. Never noticed that til now.
oh well...
but wait! What about my RSS feed? Well, my RSS reader has a cache of all comments and entries! So, I am working on a script to import everything back into typo. It's *almost* working for all the entries. Trying to do SQL inserts, is being quirky... I might try to add them one-by-one through the script via the typo web service.
It's the next day and I have imported all of my entries from my RSS reader cache file... and all my comments! What I did lose were all the email/links associated to comment posters... and they're displaying in reverse order in the comments section... but it's all there (from what I can tell).
Now, to fix that postgresql backup script to use the right version of pg_dump. :-)
In the end, I learned a lot about regular expressions in ruby and it's been a fun experience...despite almost losing all my entries to date here.