railsbp/rails_best_practices — pull request #99 by martinsvalin (2012-01-24 15:47:49+00:00)
Title: New --config option for the rails_best_practices command

Specify --config /path/to/custom_config.yml to load config from a custom location.

My reason for this change is related to my previous pull request, to have the rails_best_practices command take multiple arguments. I want to analyze a subset of my project (specifically files I'm about to commit). Some checks will give false positive, e.g. RemoveUnusedMethods*.

As I still want to be able to run rails_best_practices on my entire project will all checks, I don't want to comment out these checks in config/rails_best_practices.yml. Instead, this change lets me specify another yml-file with --config.

I hope this might be useful for others as well.