overtone / emacs-live

M-x start-hacking
http://overtone.github.com/emacs-live/
Other
1.52k stars 242 forks source link

Avoid changing the formatting on save in mode. #192

Open arichiardi opened 9 years ago

arichiardi commented 9 years ago

I would like to disable auto-cleaning/formatting on save when in clojure-mode, I found live-ignore-whitespace-modes as variable that can be set and will exclude some cleaning:

(defun live-cleanup-whitespace ()
    (if (not (member major-mode live-ignore-whitespace-modes))
        (let ((whitespace-style '(trailing empty)) )
            (whitespace-cleanup))))

Is it enough to add clojure-mode to that var?

arichiardi commented 9 years ago

I have tried: (push 'clojure-mode live-ignore-whitespace-modes) and it worked, you can close this issue if there is nothing to add..