2

I installed this package https://github.com/emacs-languagetool/flycheck-languagetool to use languagetool with emacs. However, I am getting languagetool errors at my org documents' code blocks too. How would I disable flycheck to run spell checking at my code blocks?

Barslmn
  • 21
  • 1

1 Answers1

0

This almost gives you the answer, which is:

(defun disable-fylcheck-in-org-src-block ()
  (setq-local flycheck-disabled-checkers '(languagetool)))

(add-hook 'org-src-mode-hook 'disable-fylcheck-in-org-src-block)

orgtre
  • 1,072
  • 4
  • 16
  • Almost… Description of org-src-mode-hook says: This hook will run:
    • when editing a source code snippet with ‘C-c '’
    • when formatting a source code snippet for export with htmlize.

    However, I want to disable it in the org buffer.

    In my case flycheck already runs the correct linter/checker in the src-mode.

    – Barslmn Jan 02 '23 at 09:55