« back with blogging | Main | NTFS on Mac »

Recovering from Browser Crash

 

This might apply for any website where you enter text and preview it afterwards. I experienced a browser crash when writing the preceding blog entry. And as if a browser crash wasn't annoying enogh, I discovered I didn't save my blog entry when it was finished. Instead I previewed it and headed off doing other stuff, which ended in killing browser.

Sure, as a golden rule, always copy your text before you submit any form, since any website is suspect to lose your content. But I was young and foolish and didn't do that, and even the built-in autosave mechanism of Movable Type didn't save anything helpful.

But my luck was, I did preview it. The fact of previewing it made it possible to find it in the browsers' cache. I opened the terminal and entered the following:

grep <keyword> -r ~/Library/Caches/Firefox/

whereas <keyword> is to be substituted with a word that is for sure in your text but not very common. The same could be applied to Safari, which cache is accessible under ~/Library/Caches/Safari/. The output of the grep command is the filename followed by the line in which the keyword was found. If you found the right file, you can view the contents of the file with the command cat <path/to/file>.

Post a comment