codegram/pelusa — Issue #3: Configuration file with various thresholds
Author: solnic
Created: 2012-02-15 09:41:54+00:00
State: open

It's usually very useful to have an ability to configure various thresholds so that you can set a sane starting point for your project. For example I'd like to configure pelusa to use, let's say, 80 lines of code as the initial maximum for LOC in a class or 5 as the maximum number of instance variables.

This approach favors improving the codebase step by step by updating thresholds until you reach your final goal :) This is how we do it with other metric tools (flay, flog, reek etc.) while working on DataMapper 2 libraries ([veritas](https://github.com/dkubb/veritas/tree/master/config) and [virtus](https://github.com/solnic/virtus/tree/master/config)) where we use configuration files for each of the metric tools and update thresholds while we improve the code.

I'm happy to work on a patch that adds this kind of functionality if you agree that can be useful. It's just something that I've learned while using metric tools in practice. I think starting off with very strict thresholds can be frustrating in the long term cause it can take quite a lot of time and effort until you make the metrics happy.

Anyway, thanks for the awesome tool!