(defun remove-excess-whitespace...

I always meant to go ahead and fix this function so it did what I want. Now it uses proper regex. See the old version, too.

;; ~/.emacs ;;
(defun remove-excess-whitespace () (interactive)
  (auto-mega-replace  "\\( \\|\t\\)$" ""))
(defun auto-mega-replace (arg1 arg2)
  (save-excursion
    (beginning-of-buffer)
    (while (re-search-forward arg1)
      (beginning-of-buffer)
      (perform-replace arg1 arg2
        nil t nil)
      (beginning-of-buffer))))