Don't hide compilation window

Now that I've got a different setup where I usually don't get more than
2 windows the compilation buffer pop-up isn't so annoying anymore.
This commit is contained in:
Tom Willemse 2013-05-31 12:00:18 +02:00
parent 4ed347264e
commit 11f7eadc9f

View file

@ -94,26 +94,6 @@
(defalias 'dabbrev-expand 'hippie-expand) (defalias 'dabbrev-expand 'hippie-expand)
#+END_SRC #+END_SRC
* Hide compilation window after success :compilation:
If compilation was succesfull I really don't need to see the
compilation window. So if either ~*Compilation*~ or ~*compilation*~
finishes correctly, delete the windows and show a message instead.
#+BEGIN_SRC emacs-lisp
(defun ext:comp-finish-function (buf str)
"Close the compilation buffer quickly if everything went OK."
(if (string-match "exited abnormally" str)
;; there were errors
(message "compilation errors, press C-x ` to visit")
;; no errors, make the compilation window go away in 0.5 seconds
(when (member (buffer-name) '("*Compilation*" "*compilation*"))
(delete-windows-on buf)
(message "No compilation errors!"))))
(add-to-list 'compilation-finish-functions 'ext:comp-finish-function)
#+END_SRC
* Scroll compilation window :compilation: * Scroll compilation window :compilation:
Even though I don't need to see the result of the compilation if Even though I don't need to see the result of the compilation if