from staff.tumblr.com:
Accidently blow away all your hard work on a custom theme? Don’t worry!
Tumblr now stores the last 20 revisions of your Custom HTML. To revert to a previous version, just visit the Theme Recovery page.
(found this here: http://tumblr.boxofjunk.ws/wiki/index.php?page=Useful+secret+links)