[#274] Fix apheleia-formatters-indent logic (#277)

Closes #274
This commit is contained in:
Radon Rosborough 2023-12-30 14:31:06 -07:00 committed by GitHub
parent 2b9e03a7b2
commit 923cd12108
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View file

@ -33,6 +33,10 @@ The format is based on [Keep a Changelog].
* Stylua is used now in `lua-ts-mode` as well as just `lua-mode`, by
default ([#275]).
### Bugs fixed
* Apheleia sometimes failed to determine indent level from Emacs
settings even when configured to do so. This is fixed ([#274]).
[#209]: https://github.com/radian-software/apheleia/pull/209
[#229]: https://github.com/radian-software/apheleia/pull/229
[#257]: https://github.com/radian-software/apheleia/pull/257
@ -44,6 +48,7 @@ The format is based on [Keep a Changelog].
[#264]: https://github.com/radian-software/apheleia/pull/264
[#267]: https://github.com/radian-software/apheleia/pull/267
[#271]: https://github.com/radian-software/apheleia/pull/271
[#274]: https://github.com/radian-software/apheleia/issues/274
[#275]: https://github.com/radian-software/apheleia/pull/275
## 4.0 (released 2023-11-23)

View file

@ -31,7 +31,7 @@ always returns nil to defer to the formatter."
(cond
((not apheleia-formatters-respect-indent-level) nil)
(indent-tabs-mode tab-flag)
(indent-var
(t
(unless indent-var
(setq indent-var
(cl-case major-mode