From f0d78bbe8442b97b6a654d734d10e1c1fe091442 Mon Sep 17 00:00:00 2001 From: Winston Weinert Date: Fri, 22 Nov 2024 21:28:55 -0600 Subject: [PATCH] fix(auto-dark-mode): do not error out if dark mode not possible --- configuration.org | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/configuration.org b/configuration.org index 584a32d..18dbacb 100644 --- a/configuration.org +++ b/configuration.org @@ -1067,7 +1067,12 @@ My favorite theme despite occasional low contrast. :custom (auto-dark-themes '((modus-vivendi) (modus-operandi))) :init - (auto-dark-mode)) + ;; This major mode initialization will signal an error if it cannot find a + ;; valid dark/light mode detection method. Not all computers work with this + ;; major mode. Eat the error and carry on. + (condition-case dark-err + (auto-dark-mode) + (error (message "Could not activate auto-dark-mode. Carry on.")))) #+end_src ** A facility to streamline theme selection #+BEGIN_SRC emacs-lisp