From c52d9468b3bb61de83dd2817dc3c482badd2ed4a Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Tue, 11 Mar 2025 12:09:37 -0400 Subject: [PATCH] Update README.md --- README.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index ff2ab55..a3e0846 100644 --- a/README.md +++ b/README.md @@ -738,14 +738,19 @@ To configure **flyspell**, add the following to `~/.emacs.d/post-init.el`: :defer t :commands flyspell-mode :hook - ((text-mode . flyspell-mode) - (prog-mode . flyspell-prog-mode)) + ((prog-mode . flyspell-prog-mode) + (text-mode . (lambda() + (if (or (derived-mode-p 'yaml-mode) + (derived-mode-p 'yaml-ts-mode) + (derived-mode-p 'ansible-mode)) + (flyspell-prog-mode) + (flyspell-mode 1))))) :config ;; Remove strings from Flyspell (setq flyspell-prog-text-faces (delq 'font-lock-string-face flyspell-prog-text-faces)) - ;; Remove docstrings from Flyspell + ;; Remove doc from Flyspell (setq flyspell-prog-text-faces (delq 'font-lock-doc-face flyspell-prog-text-faces))) ``` @@ -924,9 +929,6 @@ To prevent Emacs from saving customization information to a custom file, set `cu "\\|^flymake_.*")) (add-hook 'dired-mode-hook #'dired-omit-mode) -;; Enable on-the-fly spell checking (Flyspell mode). -(add-hook 'text-mode-hook #'flyspell-mode) - ;; Configure Emacs to ask for confirmation before exiting (setq confirm-kill-emacs 'y-or-n-p)