Fork me on GitHub
#editors
<
2018-06-18
>
pez10:06:27

Thanks, I’ll have a look. It’s a design decision we’ve taken with Calva Formatter as well, to not need a REPL session.

andre.stylianos10:06:05

@pez there's also zprint which does a more complete reformatting of the code than cljfmt. I've never tried it, but it looks nice. The relevant section: https://github.com/kkinnear/zprint#a-note-on-justifying-two-up-printing

pez10:06:50

@andre.stylianos: I have been looking at zprint some, and it does indeed do the aligning I am after, but it was doing a bit too much to my taste and with some use case scenarios in mind that I simply do not understand. I probably should give it a second chance, though.

pez10:06:19

My idea with formatting support is to try make the as-you-type support so good that a reformatting is seldom needed. It is my OCD, probably, but if the code do not get properly formatted automatically as I type and enter new lines I can't focus very well and to have to stop and reformat the code is not to my liking. I'm unsure wether I can achieve this with either cljfmt or zprint, but am hoping I can, because I really do not have the time to write my own formatter. 😃

4
andre.stylianos10:06:59

I'm the same as you on that part 😛 Thankfully clojure-mode plus running cljfmt on save works really well for me.

pez10:06:06

Great. That is what I am trying to achieve for Calva. Wish me luck!

🙌 4
pez10:06:52

(I already did, partially, for Calva, but it is very naive and not really something to keep building on.)