karolsluszniak / ex_check

One task to efficiently run all code analysis & testing tools in an Elixir project. Born out of 💜 to Elixir and pragmatism.
https://hex.pm/packages/ex_check
MIT License
305 stars 11 forks source link

Deps Check Unused Check #17

Closed asummers closed 3 years ago

asummers commented 3 years ago

Elixir 1.10 added a new useful check. While this can obviously be accomplished with the addition of

    {:unused_deps, command: "mix deps.unlock --check-unused"},

in .check.exs, what is the plan for doing checks that are built into the language based on the language version? Would this be something you'd want to see in ex_check?

karolsluszniak commented 3 years ago

Cool. I was not aware of this task. It looks like a worthwhile additon to curated tools, since it’s easy to forget about dropped deps.

We’d have to add another type of :detect and define the tool with that in default config. It could be {:elixir, >= 1.10.0} using Version module for resolving the condition.

asummers commented 3 years ago

Such a version detect opt could be useful to retrofit language versions and be able to compile this for older elixir versions that don't have formatter, if that was something you were interested in.

karolsluszniak commented 3 years ago

Sure, although I'm not sure it's worth the effort, i.e. if there's a demand among users of such old Elixir versions. If so, I'll gladly accept such a contribution.