-
-
Notifications
You must be signed in to change notification settings - Fork 37
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
feat: configuration file support #116
Conversation
I haven't given it a thorough workout, but I had occasion to need it today and it worked exactly as I expected. (Excluding a rule on a specific line in a specific file) I did do some quick "what interesting things can I do to break this?" checks.
So it mostly correctly handles the obvious user error cases in the config. The only thing that might be improved in that regard is erroring out when a specified line number is higher than the number of lines in the target file. This is probably a sign that the user did something that they did not mean to do (although the fact that they'd still get a message about an issue they thought they'd ignored would also be an indication) The other suggestion I have is to include a count of ignored rules when no other issues are found. The following worked for me locally. If you find it useful, feel free to take it directly or if you want I can open a PR against this branch:
|
Thanks for trial running @funnelfiasco! Yeah, a PR for that change would be great, thanks. (I agree that it'd be good to have |
PR #122 submitted (and I see you merged it in the time it took me to write the next paragraph. Talk about service!) As for the config line issue, I'm not sure I have an elegant approach. My inelegant suggestion is to do something equivalent to |
SGTM! I'll round out the docs in a bit, and then merge this and include it in a |
WIP.Fixes #12.