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 checkmake.ini overriding of minphony required targets #88

Closed
wants to merge 1 commit into from

Conversation

mcandre
Copy link

@mcandre mcandre commented Mar 21, 2023

Fixed the minphony implementation to actually support overriding from checkmake.ini file.

Long term, there is some refactoring to do in the data models and overriding logic, such as for maxbodylength and other rules. Specifically, Go tags in the models should do 90% of the work for us. And the INI library we're using already supports this:

https://ini.unknwon.io/docs/advanced/map_and_reflect

Note: The INI library appears to split by comma-with-space (unknown sensitivity to lack of space), while this patch splits by a single space delimiter.

Any special parsing/rendering requirements on top of that automatic marshaling, can be done by overriding INI marshaling methods on the data models.

But refactoring's for another day. I just want the app to work.

This fix would close #86.

If the fix is acceptable, then I would love to see this included in a new release version soon, for the benefit of us DevOps who prefer to use non-HEAD versions of our tools :)

@mrtazz
Copy link
Owner

mrtazz commented Apr 11, 2023

thanks for fixing this! Would you be up for also adding a test case that passes the config into the .Run() method and makes sure it gets properly used? Unfortunately we currently only test through configuring required targets on struct instantiation and not passing it to the method. It would be nice to more easily catch things where we don't properly take config as a run parameter into account.

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

Successfully merging this pull request may close these issues.

Unclear how to actually reconfigure the minphony rule
3 participants