Enable `writegood-mode' automatically in text modes.

This commit is contained in:
Gerard Vermeulen 2024-01-26 13:09:42 +01:00
parent 0438a6c702
commit 78b99060c4

View File

@ -4666,9 +4666,12 @@ the [[https://github.com/gromnitsky/wordnut#readme][wordnut]] prerequisites.
:CUSTOM_ID: sec:writing-writegood-mode
:END:
[[https://github.com/bnbeckwith/writegood-mode#readme][Writegood mode]] is a minor mode to aid in finding common writing problems. The post
[[http://matt.might.net/articles/shell-scripts-for-passive-voice-weasel-words-duplicates/][Matt Might's "My Ph.D. advisor rewrote himself in bash" scripts]] inspired this mode.
Listing [[lst:configure-writegood-mode]] configures [[https://github.com/bnbeckwith/writegood-mode#readme][writegood mode]].
[[https://github.com/bnbeckwith/writegood-mode#readme][Writegood mode]] is a minor mode to aid in finding common writing problems. The
post [[http://matt.might.net/articles/shell-scripts-for-passive-voice-weasel-words-duplicates/][Matt Might's "My Ph.D. advisor rewrote himself in bash" scripts]] inspired
this mode. Listing [[lst:configure-writegood-mode]] configures [[https://github.com/bnbeckwith/writegood-mode#readme][writegood mode]] and
enables =writegood-mode= for =text-mode= buffers. The best way to apply it to
this buffer is by typing {{{kbd(C-c C-e t U)}}} to export the it to a
=text-mode= buffer.
#+caption[Configure =writegood-mode=]:
#+caption: Configure =writegood-mode=.
@ -4676,7 +4679,8 @@ Listing [[lst:configure-writegood-mode]] configures [[https://github.com/bnbeckw
#+begin_src emacs-lisp -n :results silent
(when (and (ensure-package-installation 'writegood-mode)
(fboundp 'writegood-mode))
(global-set-key (kbd "C-c g") #'writegood-mode))
(global-set-key (kbd "C-c g") #'writegood-mode)
(add-hook 'after-change-major-mode-hook #'writegood-mode))
#+end_src
* Programming Tools