Sha256: 47dd12e9ab1b704a33a534f046c740347407a6f6e422523c1140b9c6f1c2b1fa
Contents?: true
Size: 632 Bytes
Versions: 30
Compression:
Stored size: 632 Bytes
Contents
# frozen_string_literal: true require 'rubycritic/analysers/helpers/flog' require 'rubycritic/colorize' module RubyCritic module Analyser class Complexity include Colorize def initialize(analysed_modules) @flog = Flog.new @analysed_modules = analysed_modules end def run @analysed_modules.each do |analysed_module| @flog.reset @flog.flog(analysed_module.path) analysed_module.complexity = @flog.total_score.round(2) print green '.' end puts '' end def to_s 'complexity' end end end end
Version data entries
30 entries across 30 versions & 2 rubygems