mirego / credo_naming

🏷 A suite of Credo checks to enforce naming best practices in an Elixir project
https://open.mirego.com
BSD 3-Clause "New" or "Revised" License
88 stars 9 forks source link

Support for enforcing team conventions #21

Closed bglusman closed 4 months ago

bglusman commented 2 years ago

We're considering trying to use credo to create and enforce some standards around module hierarchy/organization... it's not a fully fleshed out plan yet, but I wonder if other people have similar needs/tools and if perhaps we can build or leverage something somewhat general for better community support, and if this would be a good place to do it if there's interest. I'm imagining something like a way to represent the hierarchy of modules in one canonical place, and then the tool can warn or error if names from inside that hierarchy occur in locations other than that described by the hierarchy? but like I said, it's not fully fleshed out yet, just want to explore the idea and others thoughts on the subject.

remi commented 2 years ago

Hi Brian,

I’m not sure how to approach this.

Would you be able to implement this convention using the valid_filename? callback option or is it something more complex? What do you have in mind for implementation?

bglusman commented 5 months ago

Sorry I'm so late responding! I didn't know about valid_filename? callback, that seems like a good starting place to experiment!

remi commented 4 months ago

@bglusman I’m going to close this. Hopefully valid_filename? helped you!