summaryrefslogtreecommitdiff
path: root/.emacs.d
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2022-05-19 09:39:26 -0700
committerSean Whitton <spwhitton@spwhitton.name>2022-05-19 17:29:16 -0700
commit3d0240a4461c5fec3cc49f3d481d6c58cc95d204 (patch)
treeb9703b7d32b2e5a834830571fd21a4259dd262e6 /.emacs.d
parent4a7a32e7d980e2afac1df5707afd231962f916ff (diff)
downloaddotfiles-3d0240a4461c5fec3cc49f3d481d6c58cc95d204.tar.gz
spw/window-toggle-side-windows: handle case of SLIME not connected
Diffstat (limited to '.emacs.d')
-rw-r--r--.emacs.d/init.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index 999f1ea6..d099e891 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -874,7 +874,10 @@ state, attempt to produce some useful side window(s)."
(cond ((and (project-current)
(directory-files
(project-root (project-current)) nil "\\.asd\\'"))
- (slime-switch-to-output-buffer))
+ (if (ignore-errors (slime-output-buffer))
+ (slime-switch-to-output-buffer)
+ (let ((default-directory (expand-file-name "~/")))
+ (slime))))
(t (error "No side windows state & no heuristic")))))))
(global-set-key "\C-cs" #'spw/window-toggle-side-windows)