Hi there! And @pez, I’m a little bit out of context reading this from the thread, let me check the conversation on the channel.
This particular thread is about where the conversation started in the channel: that Calva and Calva Formatter disagrees about some formatting. So, when Calva has helped you get all new lines indented and carefully tried to honor some one-indent-form guidelines, and you format the document, things are reindented differently, and in particular, one-indents are thrown out the window.
Looking at cljfmt
documentation, it looks like we could try to tweak a few knobs, like this one for example :cljfmt {:indents ^:replace {#".*" [[:inner 0]]}}
> If you want to override all existing indents, instead of just supplying new indents that are merged with the defaults, you can use the :replace hint:
Changing some cljfmt (that’s the formatting library that Calva uses) knobs might work, but it would even better to actually use cljfmt APIs to format as you type.
But I don’t know if there’s such API, I need to check the code.
I was actually going to try use cljfmt for ontype formatting for this very reason, I am sick of the formatting wars and it does not feel good to be publishing extensions that engage in this war against each other! 😃
So if we can pour the one-indent-forms from Calva into that regexp, that will be very awesome. I might try today!