Auto-save the scratch buffer when Emacs exits