aboutsummaryrefslogtreecommitdiff
path: root/apheleia-formatters.el
diff options
context:
space:
mode:
authorRadon Rosborough <radon@intuitiveexplanations.com>2023-12-21 19:52:55 -0800
committerGitHub <noreply@github.com>2023-12-21 20:52:55 -0700
commitb2d2b50f1a8b4cfcb7aa9fa815017bac26552da9 (patch)
tree98ccfade322b5bac2885735803a1089fff5ec780 /apheleia-formatters.el
parent93f7480c967ef9104933f6e346a562196a670d86 (diff)
[#220] Disable in jinja2-mode by default (#238)
Close #220
Diffstat (limited to 'apheleia-formatters.el')
-rw-r--r--apheleia-formatters.el9
1 files changed, 8 insertions, 1 deletions
diff --git a/apheleia-formatters.el b/apheleia-formatters.el
index 606e3e2..019fecb 100644
--- a/apheleia-formatters.el
+++ b/apheleia-formatters.el
@@ -321,6 +321,7 @@ rather than using this system."
(html-ts-mode . prettier-html)
(java-mode . google-java-format)
(java-ts-mode . google-java-format)
+ (jinja2-mode . nil)
(js3-mode . prettier-javascript)
(js-json-mode . prettier-json)
(js-mode . prettier-javascript)
@@ -382,7 +383,13 @@ If a given mode derives from another mode (e.g. `php-mode' and
`cc-mode'), then whichever entry in the alist is more specific
will apply. In the case that multiple modes match
`derived-mode-p' for the current buffer but neither derives from
-the other, whichever entry comes first will be used."
+the other, whichever entry comes first will be used.
+
+The value for a major mode can be nil (equivalently, an empty
+list). This means to use no formatter. This can be helpful in
+case your major mode derives from a more general one, but you
+don't want the more general formatter to apply to the derived
+mode."
:type '(alist
:key-type
(choice (symbol :tag "Major mode")