aboutsummaryrefslogtreecommitdiff
path: root/modules/keyboard-macros.el
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2025-10-23 00:15:14 -0500
committerCraig Jennings <c@cjennings.net>2025-10-23 00:15:14 -0500
commitbd559d3b87438469fb27c6c5da63747df451f3ff (patch)
tree516652c77741824f0c1405e28a19b3acd218fd18 /modules/keyboard-macros.el
parent520dc8f3d31d590f8990087c427e6ca8bb43363b (diff)
downloaddotemacs-bd559d3b87438469fb27c6c5da63747df451f3ff.tar.gz
dotemacs-bd559d3b87438469fb27c6c5da63747df451f3ff.zip
refactor: unify and simplify key binding setups
Optimized key binding configurations across modules for consistency and reduced redundancy. Improved conditional requiring to handle errors gracefully in `music-config.el`, ensuring robustness across different machine environments. Eliminated comments clutter and adjusted function definitions to adhere to revised standards.
Diffstat (limited to 'modules/keyboard-macros.el')
-rw-r--r--modules/keyboard-macros.el6
1 files changed, 2 insertions, 4 deletions
diff --git a/modules/keyboard-macros.el b/modules/keyboard-macros.el
index a18fd6942..5cd89f210 100644
--- a/modules/keyboard-macros.el
+++ b/modules/keyboard-macros.el
@@ -34,9 +34,7 @@
;;; Code:
(require 'subr-x) ;; for string-trim
-
-;; Declare external variable to avoid compile warnings
-(defvar macros-file)
+(eval-when-compile (require 'user-constants))
(defvar cj/macros-loaded nil
"Whether saved keyboard macros have been loaded from file.")
@@ -61,7 +59,7 @@ This function is idempotent and fast when macros are already loaded."
(setq cj/macros-loading nil)))
(defun ensure-macros-file (file)
- "Ensure FILE exists and its first line enables \='lexical-binding\='."
+ "Ensure FILE exists and its first line enables `lexical-binding'."
(unless (file-exists-p file)
(with-temp-file file
(insert ";;; -*- lexical-binding: t -*-\n"))))