lib/sorbet_progress/cli.rb in sorbet-progress-0.2.4 vs lib/sorbet_progress/cli.rb in sorbet-progress-0.2.5
- old
+ new
@@ -23,10 +23,11 @@
end
@path = argv.first
end
sig { void }
+ # rubocop:disable Metrics/AbcSize
def run
metrics = parse(@path)
puts "Sorbet Progress\n\n"
stats_calculator = Calculator.new(metrics)
@@ -43,17 +44,23 @@
if elem[:percentage]
elem[:percentage] * 100
else
0
end
- puts format("%-17s\t%d\t%.2f %%", elem[:label], elem[:value] || 0, percentage)
+ puts format(
+ "%-17s\t%d\t%.2f %%",
+ elem[:label],
+ elem[:value] || 0,
+ percentage
+ )
end
puts "---------------------------------------"
puts "Total: \t\t\t#{stats_calculator.total}\t100%"
puts "Keep up the good work 👍"
end
+ # rubocop:enable Metrics/AbcSize
private
sig { params(path: String).returns(Metrics) }
def parse(path)