rubycritic
rubycritic copied to clipboard
Settings file
Instead of having settings purely as flags, it would be interesting to have a configuration file, which could be ported and used across several projects.
I agree, I think a rubycritic.yml
file would be a good candidate for how we handle settings.
In debt_ceiling I use the Confirguations gem, and read in a ruby file with rails like configuration block... I think I prefer that to yml, but agree having settings/config is a good idea.
+1. It would be great to specify in a config file which folders ruby critic should critique.
Agree, would be useful. Would somebody like to take a stab at this? ;)
The same comment I wrote for #11 applies here:
Due to RC's nature this is not really trivial since we aggregate multiple tools and those tools have a different understanding of how you can exclude and include paths. And some might not even offer an "exclude" functionality. Nevertheless I can see that this feature would be highly valuable.
;)
I am working on this, using yml (rubycritic.yml
) file.
@nav16 Any updates on this? I have a project right now where we patch a gem and it is very picky about how we patch it. This file is the only thing that's not an 'A' and is keeping me from doing a -s 100
on our ci build
It would be nice if the rubycritic config was basically just an extended version of the Reek config — so we could copy our current Reek configuration into it, and add other configuration options for the other tools (flog, flay, etc.) and for rubycritic itself.
Or maybe provide a rubycritic config directory that can contain config files specific to each tool (e.g., .rubycritic/.reek
).
In particular, I want to be able to configure skipping some of the checks from Flog and Flay (e.g., HighComplexity
, DuplicateCode
) for specific directories (e.g., spec
), without having to ignore those directories for everything else.
Right now, my rubycritic my report gets filled up with lots of complexity and duplicate code smells from my spec directory, unless I don’t include the spec directory (and miss out on reporting the code smells I do want to see for specs).
Thanks!
I guess this can be closed, since we can use .reek.yml
as a configuration file.