Keep emacs from pooping ~ files about

Emacs craps little backup~ files all over the place. While this is great when you have no version control and you make a mistake, these days, we all use version control (right?). These backup files are just annoying, clutter up logs and searching, and can even be a security hole if you leave them in a web accessible directory or fail to clean up permissions.

So, put this in the .emacs file in your home directory (create it if it doesn't exist)

(setq backup-inhibited 'anyvaluebutnil )

This keeps emacs from writing any new backup files.

To clean up the ones~ that are already there, first make sure that you don't want anything out of those files (or even better, put the important parts under version control) then do:

find ./ -name '*~' -exec rm '{}' \; -print -or -name ".*~" -exec rm {} \; -print

This will delete them all.