From 00180310df78e210c6ba4de185dd703f5f78ed16 Mon Sep 17 00:00:00 2001 From: Benjamin Andresen Date: Sun, 6 Aug 2017 15:44:27 +0200 Subject: [PATCH] Add: app/irc: (=irc) if irc workspace exists switch to that don't connect to the networks again --- modules/app/irc/autoload/irc.el | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/app/irc/autoload/irc.el b/modules/app/irc/autoload/irc.el index 388410492..1e1f01210 100644 --- a/modules/app/irc/autoload/irc.el +++ b/modules/app/irc/autoload/irc.el @@ -20,9 +20,11 @@ If INHIBIT-WORKSPACE (the universal argument) is non-nil, don't spawn a new workspace for it." (interactive "P") - (and (+irc-setup-wconf inhibit-workspace) - (cl-loop for network in circe-network-options - collect (circe (car network))))) + (if (+workspace-exists-p +irc--workspace-name) + (+workspace-switch +irc--workspace-name) + (and (+irc-setup-wconf inhibit-workspace) + (cl-loop for network in circe-network-options + collect (circe (car network)))))) ;;;###autoload (defun +irc/connect (&optional inhibit-workspace)