From c3ff6dc08c8c2a30f9880f80a54651344700b27d Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Sun, 6 Feb 2022 22:17:25 -0600 Subject: Add chat --- lisp/acdw.el | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'lisp/acdw.el') diff --git a/lisp/acdw.el b/lisp/acdw.el index 916591c..2f4e0fc 100644 --- a/lisp/acdw.el +++ b/lisp/acdw.el @@ -87,9 +87,11 @@ If body executes without errors, MESSAGE...Done will be displayed." (declare (indent 1)) (let ((msg (gensym))) `(let ((,msg ,message)) - (unwind-protect (progn (message "%s..." ,msg) - ,@body) - (message "%s...done" ,msg))))) + (condition-case e + (progn (message "%s..." ,msg) + ,@body) + (:success (message "%s...done" ,msg)) + (t (signal (car e) (cdr e))))))) (defun +mapc-some-buffers (func &optional predicate) "Perform FUNC on all buffers satisfied by PREDICATE. @@ -267,5 +269,18 @@ always nil; this function is mostly intended for use in init." (dolist (spec specs) (apply #'set-face-attribute (car spec) nil (cdr spec)))) +(defcustom chat-functions '(+irc + jabber-connect-all + slack-start) + "Functions to start when calling `chat'." + :type '(repeat function) + :group 'applications) + +;; I can never remember all the damn chat things I run, so this just does all of em. +(defun chat () + "Initiate all chat functions." + (interactive) + (mapc #'call-interactively chat-functions)) + (provide 'acdw) ;;; acdw.el ends here -- cgit 1.4.1-21-gabe81