From ad563d4031be59413979148b23a54e76ec3a778c Mon Sep 17 00:00:00 2001 From: eriedaberrie Date: Sun, 14 Jan 2024 22:22:01 -0800 Subject: [PATCH] Replace spell-fu with jinx --- init.el | 47 +++-------------------------------------------- 1 file changed, 3 insertions(+), 44 deletions(-) diff --git a/init.el b/init.el index 4cc23c1..24e66d7 100644 --- a/init.el +++ b/init.el @@ -590,57 +590,16 @@ (use-package meson-mode) -(use-package spell-fu - :hook - text-mode - (org-mode . (lambda () - (setq spell-fu-faces-exclude - '(org-block-begin-line - org-block-end-line - org-code - org-date - org-drawer org-document-info-keyword - org-ellipsis - org-link - org-meta-line - org-properties - org-properties-value - org-special-keyword - org-src - org-tag - org-verbatim))))) +(use-package jinx + :hook text-mode) (use-package minimap :custom-face (minimap-active-region-background ((t (:background unspecified :inherit hl-line)))) :hook (minimap-sb-mode . turn-on-solaire-mode)) -(defun my-magit-spell-fu-check-range (pos-beg pos-end) - (spell-fu--overlays-remove pos-beg pos-end) - (with-syntax-table spell-fu-syntax-table - (save-match-data - (save-excursion - (goto-char (point-min)) - (let ((check-end (-> (format "^%s -+ >8 -+$" comment-start) - (re-search-forward pos-end t) - (or pos-end))) - (comment-start-char (aref comment-start 0))) - (goto-char pos-beg) - (while (< (point) check-end) - (unless (= (char-after) comment-start-char) - (let ((pos-line-end (pos-eol))) - (while (re-search-forward spell-fu-word-regexp pos-line-end t) - (let ((word-beg (match-beginning 0)) - (word-end (match-end 0))) - (spell-fu-check-word word-beg word-end (match-string-no-properties 0)))))) - (forward-line))))))) - (use-package magit - :hook (git-commit-setup . (lambda () - (git-commit-turn-on-auto-fill) - (spell-fu-mode) - (setq-local spell-fu-check-range #'my-magit-spell-fu-check-range) - (spell-fu--time-ensure t)))) + :hook (git-commit-setup . git-commit-turn-on-auto-fill)) (use-package forge :after magit