summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2025-11-08 12:40:15 -0600
committerCraig Jennings <c@cjennings.net>2025-11-08 12:40:15 -0600
commitad9099f489b5d0ab89d23566c386c915cd92db06 (patch)
treea6fef34cb3204dcfe3c80e16e2d33ffd227429fb
parent04b11059b831c94b4e5ba901b735fcc888cbbe1a (diff)
docs: Use :preface for wttrin-debug instead of external setq
Update README to show wttrin-debug being set in :preface section of use-package declarations. This is cleaner and follows standard use-package conventions better than requiring users to set variables outside the declaration. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
-rw-r--r--README.org17
1 files changed, 8 insertions, 9 deletions
diff --git a/README.org b/README.org
index fb8b085..275a51e 100644
--- a/README.org
+++ b/README.org
@@ -240,15 +240,15 @@ You can customize several aspects of the mode-line weather display:
If wttrin isn't working as expected, enable debug mode to see detailed logging of what's happening.
*** Enabling Debug Mode
-*Important:* The `wttrin-debug` variable must be set *before* wttrin loads, as it's checked at load time to decide whether to load the debug module.
+*Important:* The `wttrin-debug` variable must be set *before* wttrin loads, as it's checked at load time to decide whether to load the debug module. Use `:preface` to set it before the package loads.
**** For use-package installations:
#+begin_src emacs-lisp
- ;; Set debug BEFORE the use-package declaration
- (setq wttrin-debug t)
-
(use-package wttrin
:ensure t
+ :preface
+ ;; Set debug BEFORE wttrin loads
+ (setq wttrin-debug t)
:custom
(wttrin-mode-line-favorite-location "Your City"))
#+end_src
@@ -266,14 +266,13 @@ If wttrin isn't working as expected, enable debug mode to see detailed logging o
#+begin_src emacs-lisp
(add-to-list 'load-path "/path/to/emacs-wttrin")
- ;; Set debug BEFORE (require 'wttrin)
- (setq wttrin-debug t)
-
(use-package wttrin
:preface
+ ;; Load dependencies and set debug BEFORE wttrin loads
(use-package xterm-color :demand t)
- ;; ... rest of config
- )
+ (setq wttrin-debug t)
+ :custom
+ (wttrin-mode-line-favorite-location "Your City"))
#+end_src
*** Viewing Debug Output