@b0rk more of a confession than a useful answer but my inability to type “destroy” correctly when typing fast has prevented more than one botched “zfs destroy foo” from turning into a painful restore session. There might be a UX lesson in there somewhere.
@b0rk perhaps more useful: when using git I prefer to avoid using subcommands that do “to much”. I never use “git pull”. I don’t admit the existing of “git add -a” and avoid “git add <dir>” without -p. It try to check “git status” and “git diff --staged”.
I’ve also learned to recover using “git reflog” and “git reset --hard” when I do manage to blow things up. (Though the latter misapplied is the main way I’ve lost work by accident.)