-
Notifications
You must be signed in to change notification settings - Fork 153
Need a an option to hide 'requires chef server checks' #4
Comments
Hi Alan, Glad you asked for this. The FAQ I added recently touches on this: There's no support right now for tailoring which warnings you are interested in. I have grandiose ideas of a JSON file (ok not that grandiose) to define a 'policy' or bunch of rules you care about. However I think a simple command-line flag that let you specify includes / excludes would get you most of the way there for now? Something like I can probably take a look at this tomorrow, or if you feel like submitting a pull request that would be cool. There's also some need for the concept of severity so you can choose to ignore warnings for style completely if you wish to for example. Are you looking at using this within CI (Jenkins)? If so you'd probably want foodcritic to return a non-zero exit code to fail the build if warnings were issued. Additionally adding support for foodcritic to the Jenkins Warning Plugin would be very cool I think. |
The DSL now accepts a tags array to define the set of tags available to choose whether or not to apply the rule. This is lifted straight from Cucumber tag expressions.
I've pushed some changes to master that let you specify tags on the command line to include / exclude rules. For example you can exclude Chef Solo related warnings by running foodcritic like so: This needs some better tests before I release an updated gem but I'd appreciate any feedback you can give before then. Cheers, Andrew. |
Hi, This has been released in foodcritic 0.5.0. Let me know if you have any issues. |
Hi Alan, Have you had a chance to try this? |
Closing this as delivered. Feel free to re-open if it's not quite what you want. |
Basically I want to wire this up to my chef repo, with the goal being no alerts generated, and in my case I know I need chef server
The text was updated successfully, but these errors were encountered: