summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKyle Meyer <kyle@kyleam.com>2014-04-19 22:01:12 -0400
committerKyle Meyer <kyle@kyleam.com>2014-04-19 22:01:12 -0400
commite87a42046f66882d02252cbb75342887062f0f78 (patch)
tree749979dd2a36a6e57910422fa465a54b208ed0c7
parentfac178db803b4f4f06e746da4ab6a408ddb54cb5 (diff)
downloademacs.d-e87a42046f66882d02252cbb75342887062f0f78.tar.gz
Add command: km/display-compilation-other-window
-rw-r--r--lisp/init-external.el7
1 files changed, 7 insertions, 0 deletions
diff --git a/lisp/init-external.el b/lisp/init-external.el
index 02cabbe..c9d39ae 100644
--- a/lisp/init-external.el
+++ b/lisp/init-external.el
@@ -24,6 +24,12 @@ other window when an asynchronous command is run."
(interactive)
(ansi-term "/bin/zsh"))
+(defun km/display-compilation-other-window ()
+ (interactive)
+ (-if-let (comp-buffer (get-buffer "*compilation*"))
+ (display-buffer comp-buffer)
+ (error "No compilation buffer")))
+
(define-key external-map "a" 'km/zsh-ansi-term)
(define-key external-map "t" 'km/open-external-terminal)
(define-key external-map "r" 'shell-command-on-region)
@@ -32,6 +38,7 @@ other window when an asynchronous command is run."
(define-key external-map "c" 'compile)
(define-key external-map "g" 'recompile)
+(define-key external-map "o" 'km/display-compilation-other-window)
(define-key external-map "w" 'woman)