From 206befd15f98b86346b9af76fe9219eeca924c0e Mon Sep 17 00:00:00 2001 From: Austin Bingham Date: Fri, 28 Sep 2018 09:33:35 +0200 Subject: [PATCH] Added org-mode to list of modes supported by default. --- README.md | 10 +++++++++- flycheck-vale.el | 4 +--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3e44fb1..0cf0a2e 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ To use `flycheck-vale` just `require` it and run `flycheck-vale-setup`: (flycheck-vale-setup) ``` -## Dis/enabling flycheck vale for specific buffers +## Dis/enabling `flycheck-vale` for specific buffers The buffer-local variable `flycheck-vale-enabled` allows you to enabled or disable vale linting for specific buffers. If this variable is `t` then vale @@ -30,3 +30,11 @@ Likewise, if it is `nil` then vale linting will never be performed. You can use `flycheck-vale-toggle-enabled` to toggle this variable between `t` and `nil`. (And of course you can set it other ways if you want.) By default the variable is `t`. + +## Enabling `flycheck-vale` for new modes + +By default `flycheck-vale` will only be enabled for the modes in +`flycheck-vale-modes` (currently `text-mode`, `markdown-mode`, `rst-mode`, and +`org-mode`). To enable it for some other mode, use the function +`flycheck-add-mode`. If you think that this mode should be supported by +`flycheck-vale` by default, bring it up in an issue. diff --git a/flycheck-vale.el b/flycheck-vale.el index 5e4c0b3..817aede 100644 --- a/flycheck-vale.el +++ b/flycheck-vale.el @@ -58,9 +58,7 @@ :type '(string) :group 'flycheck-vale) -(defcustom flycheck-vale-modes '(text-mode markdown-mode rst-mode) - "List of major modes in which to apply this checker." - :type '(repeat function)) +(defconst flycheck-vale-modes '(text-mode markdown-mode rst-mode org-mode)) (defcustom flycheck-vale-output-buffer "*flycheck-vale*" "Buffer where tool output gets written."