News for hackers. Stuff that matters.
Re:GNU Emacs 23.2 released by imurray on Saturday May 08, 2010 @11:23AM (#1330285)
Having once managed to delete a file with hours of edits just before committing to version control, I opened my 60 GB partition in vim, found the text of the file and copied it out. While this is "stupid" — there will be better ways to do it — searching and recovering with vim worked immediately and easily.

Edit: it's possible I used "less", I can't remember.

Re:GNU Emacs 23.2 released by __mlm__ on Saturday May 08, 2010 @03:15PM (#1330734)
Can you explain in just a bit more detail how you did this? This sounds really neat. I faced a problem like this a while ago, but luckily the file was still open in emacs (and in an emacs buffer), so I just re-wrote it back to disk.
Re:GNU Emacs 23.2 released by imurray on Saturday May 08, 2010 @03:54PM (#1330805)
This was a linux laptop. I immediately powered off and booted with a live CD. To be honest I'm not sure exactly what I did next. I might have just done "less -f /dev/sda5". I think what I actually did was make an image of the partition using dd to an external drive so I would be able to recover the file at leisure. Trying now, it seems that vim won't open a /dev block device directly, but an image is just a regular file.
Re:GNU Emacs 23.2 released by nkassis on Saturday May 08, 2010 @11:40AM (#1330313)
Hehe, cool trick, I'll have to try it out someday :)