diff --git a/core/autoload/text.el b/core/autoload/text.el index cbb4af2f7..8c08c5a67 100644 --- a/core/autoload/text.el +++ b/core/autoload/text.el @@ -62,7 +62,7 @@ POS defaults to the current position." ;; -;; Commands +;;; Commands (defvar doom--last-backward-pt most-positive-fixnum) ;;;###autoload @@ -247,7 +247,7 @@ editorconfig or dtrt-indent installed." ;; -;; Hooks +;;; Hooks ;;;###autoload (defun doom-enable-delete-trailing-whitespace-h () diff --git a/core/core-keybinds.el b/core/core-keybinds.el index fb305bd23..a79258aee 100644 --- a/core/core-keybinds.el +++ b/core/core-keybinds.el @@ -49,10 +49,10 @@ and Emacs states, and for non-evil users.") ;; `keyboard-quit', but this is much more intuitive. (defvar doom-escape-hook nil - "A hook run after C-g is pressed (or ESC in normal mode, for evil users). Both -trigger `doom/escape'. + "A hook run when C-g is pressed (or ESC in normal mode, for evil users). -If any hook returns non-nil, all hooks after it are ignored.") +More specifically, when `doom/escape' is pressed. If any hook returns non-nil, +all hooks after it are ignored.") (defun doom/escape () "Run `doom-escape-hook'." @@ -414,7 +414,6 @@ Properties USE THIS IN YOUR PRIVATE CONFIG. :after [FEATURE] [...] apply keybinds when [FEATURE] loads :textobj KEY INNER-FN OUTER-FN define a text object keybind pair - :if [CONDITION] [...] :when [CONDITION] [...] :unless [CONDITION] [...] diff --git a/core/core-ui.el b/core/core-ui.el index 0bb878b04..b9b62aaf2 100644 --- a/core/core-ui.el +++ b/core/core-ui.el @@ -482,7 +482,7 @@ treat Emacs as a non-application window." (add-hook! '(completion-list-mode-hook Man-mode-hook) #'hide-mode-line-mode) -;; Better fontification of number literals in code +;; Many major modes do no highlighting of number literals, so we do it for them (use-package! highlight-numbers :hook ((prog-mode conf-mode) . highlight-numbers-mode) :config (setq highlight-numbers-generic-regexp "\\_<[[:digit:]]+\\(?:\\.[0-9]*\\)?\\_>")) @@ -661,7 +661,7 @@ startup (or theme switch) time, so long as `doom--prefer-theme-elc' is non-nil." "Initialize Doom's user interface by applying all its advice and hooks." (run-hook-wrapped 'doom-init-ui-hook #'doom-try-run-hook) - (add-to-list 'kill-buffer-query-functions #'doom-protect-fallback-buffer-h nil 'eq) + (add-hook 'kill-buffer-query-functions #'doom-protect-fallback-buffer-h) (add-hook 'after-change-major-mode-hook #'doom-highlight-non-default-indentation-h 'append) ;; Initialize custom switch-{buffer,window,frame} hooks: diff --git a/modules/lang/rust/config.el b/modules/lang/rust/config.el index ec0397c8e..6bbe39b04 100644 --- a/modules/lang/rust/config.el +++ b/modules/lang/rust/config.el @@ -69,7 +69,7 @@ ;; that behavior. ((symbol-function #'rustic-install-rls-client-p) (lambda (&rest _) - (message "No RLS server running.")))) + (message "No RLS server running")))) (apply orig-fn args)))) diff --git a/modules/tools/editorconfig/config.el b/modules/tools/editorconfig/config.el index cecafdc4e..3c4a6d643 100644 --- a/modules/tools/editorconfig/config.el +++ b/modules/tools/editorconfig/config.el @@ -20,7 +20,7 @@ ;; Handles whitespace (tabs/spaces) settings externally. This way projects can ;; specify their own formatting rules. (use-package! editorconfig - :after-call (doom-switch-buffer-hook after-find-file) + :after-call doom-switch-buffer-hook after-find-file :config (defadvice! +editorconfig--smart-detection-a (orig-fn) "Retrieve the properties for the current file. If it doesn't have an @@ -30,7 +30,7 @@ extension, try to guess one." (if (and (not (bound-and-true-p org-src-mode)) (file-name-extension buffer-file-name)) buffer-file-name - (format "%s%s" buffer-file-name + (format "%s%s" (buffer-file-name (buffer-base-buffer)) (if-let* ((ext (cdr (assq major-mode +editorconfig-mode-alist)))) (concat "." ext) "")))))