square/cane — pull request #15 by yob (2012-06-17 12:38:59+00:00)
Title: New Check: all ruby files should have an encoding marker

I have a project where team style dictates that every ruby file should have an encoding marker.

This is admittedly not something every team wants and wouldn't be a good default check.

Implementing the check was straight forward ( cf7e549d ), however I was surprised at the size of the subsequent commit that wired it into cane ( ba85d410 ).

What do you think about an addition to the rake task that allows teams to load custom checks? Something like:

Cane::RakeTask.new(:cane) do |cane|
cane.use EncodingCheck.new
cane.use MethodLengthCheck.new(15)
cane.use ObscureTeamCheck.new
cane.use FilteredParamsCheck.new
end
end