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

Add Igniter? #102

Open
kevinschweikert opened this issue Jul 28, 2024 · 3 comments
Open

Add Igniter? #102

kevinschweikert opened this issue Jul 28, 2024 · 3 comments

Comments

@kevinschweikert
Copy link

kevinschweikert commented Jul 28, 2024

Hey, I just read this article about the new igniter tool and Credo was mentioned to benefit from it. How do you think about this? Would you accept a PR to add igniter to this project?

@rrrene rrrene transferred this issue from rrrene/credo Jul 29, 2024
@rrrene
Copy link
Owner

rrrene commented Jul 29, 2024

Hi, I moved this issue to the right repo. Please read the issue template when creating an issue instead of deleting it.

Regarding your question: I will probably not, as I cannot read your mind with regards to what a PR would contain specifically 🤷‍♂️

edit: To clarify: I might very well be interested in your idea for a feature, of course. That is a big part of open source. But so far, you just mentioned some tech you want to use.

@kevinschweikert
Copy link
Author

Totally! And I definitely should have read the template, even in my excitement for a good idea! Thanks for transferring it to the right place.

To cite the Igniter docs

Igniter is a code generation and project patching framework.

For library authors, this is a tool kit for writing smarter generators that can semantically modify existing files, and all sorts of useful tools for doing so.

and the part of the article I was referring

When working users initially set up credo , they will typically run mix credo.gen.config to generate a configuration file. This configuration file contains all of the checks that credo knows about when the config was generated. What this means is that when new Credo checks are created added by its maintainers, there is no reasonable way to automatically include them in your config file without monitoring how the project is changed, what the new modules are, etc.

This is basically already it. In the past, I went through the CHANGELOG and was manually checking if there were some new or updated credo checks available. I liked the proposed idea of the article and felt motivated to try it if you would be interested in this integration.

I haven't worked with Igniter so i don't know exactly what needs to be done. But from the docs it seems that you just need to write a custom mix task.

@rrrene
Copy link
Owner

rrrene commented Aug 13, 2024

This is probably at the center of the proposal, to have a way to tell if there are new checks available.
I think that this could be a great feature! 💯

I am not super happy with the idea of adding all the transitive deps that igniter would bring, as it would roughly double Credo's total dependency count.

We could probably work something out that covers the core use-case in a leaner way without adding so much potential debt, especially since I think that we haven't specified what the command (we are talking about a command, right?) would be doing (it seems you want to edit some files automatically, but what does that mean, specifically?).

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

No branches or pull requests

2 participants