diff --git a/CHANGELOG.md b/CHANGELOG.md index 938afe1d..de3fb900 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,10 @@ The format is based on [Keep a Changelog]. [#134] and [#138]. * `apheleia-mode` lighter is now customizable ([#143]). +### Enhancements +* Emacs 29's tree-sitter-based major modes have been added to + `apheleia-mode-alist` ([#145]). + ### Bugs fixed * If a formatter exited with a zero exit code when being killed by a signal (even though that is really weird behavior and arguably a bug @@ -31,6 +35,7 @@ The format is based on [Keep a Changelog]. [#137]: https://github.com/radian-software/apheleia/pull/137 [#138]: https://github.com/radian-software/apheleia/pull/138 [#143]: https://github.com/radian-software/apheleia/pull/143 +[#145]: https://github.com/radian-software/apheleia/pull/145 ## 3.1 (released 2022-11-11) ### Enhancements diff --git a/apheleia.el b/apheleia.el index b14c0195..3d0bd0cb 100644 --- a/apheleia.el +++ b/apheleia.el @@ -1122,15 +1122,20 @@ function: %s" command))) (php-mode . phpcs) ;; json-mode has to come before javascript-mode (aka js-mode) (json-mode . prettier-json) + (json-ts-mode . prettier-json) ;; rest are alphabetical + (bash-ts-mode . shfmt) (beancount-mode . bean-format) + (c++-ts-mode . clang-format) (cc-mode . clang-format) (c-mode . clang-format) + (c-ts-mode . clang-format) (c++-mode . clang-format) (caml-mode . ocamlformat) (common-lisp-mode . lisp-indent) (crystal-mode . crystal-tool-format) (css-mode . prettier-css) + (css-ts-mode . prettier-css) (dart-mode . dart-format) (elixir-mode . mix-format) (elm-mode . elm-format) @@ -1140,8 +1145,10 @@ function: %s" command))) (haskell-mode . brittany) (html-mode . prettier-html) (java-mode . google-java-format) + (java-ts-mode . google-java-format) (js3-mode . prettier-javascript) (js-mode . prettier-javascript) + (js-ts-mode . prettier-javascript) (kotlin-mode . ktlint) (latex-mode . latexindent) (LaTeX-mode . latexindent) @@ -1149,6 +1156,7 @@ function: %s" command))) (lisp-mode . lisp-indent) (nix-mode . nixfmt) (python-mode . black) + (python-ts-mode . black) (ruby-mode . prettier-ruby) (rustic-mode . rustfmt) (rust-mode . rustfmt) @@ -1159,6 +1167,7 @@ function: %s" command))) (TeX-mode . latexindent) (tuareg-mode . ocamlformat) (typescript-mode . prettier-typescript) + (typescript-ts-mode . prettier-typescript) (web-mode . prettier) (yaml-mode . prettier-yaml)) "Alist mapping major mode names to formatters to use in those modes.