Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support "indent like" configuration #60

Open
robhanlon22 opened this issue Aug 18, 2020 · 2 comments
Open

Support "indent like" configuration #60

robhanlon22 opened this issue Aug 18, 2020 · 2 comments

Comments

@robhanlon22
Copy link
Contributor

robhanlon22 commented Aug 18, 2020

clj-kondo has a nice feature where you can configure it to lint a particular macro as if it were a different macro, so you don't have to write custom linters for macros if they're not necessary. That got me thinking—it would be really nice if cljstyle supported something like that in the :indents configuration, e.g.

;; .cljstyle
{:indents {def-special-fn defn}}

Would indent def-special-fn like defn. It might even be worth adding a new configuration key so you could opt into certain special formats, as the example above wouldn't format its arg vector liked defn.

@greglook
Copy link
Owner

Yup! I have been playing with a similar idea; this and a few other issues have led me to want to revamp how cljstyle config is structured to make it more rule-focused instead of a large flat map. Unfortunately I haven't had a lot of spare time to work on this lately (puppies are hard 😭) but I'm hoping to get it done this month.

@robhanlon22
Copy link
Contributor Author

Yup! I have been playing with a similar idea; this and a few other issues have led me to want to revamp how cljstyle config is structured to make it more rule-focused instead of a large flat map. Unfortunately I haven't had a lot of spare time to work on this lately (puppies are hard 😭) but I'm hoping to get it done this month.

PUPPIES

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants