Class: Lock::Gemfile::Report

Inherits:
Object
  • Object
show all
Defined in:
lib/lock/gemfile/report.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.generateObject



9
10
11
# File 'lib/lock/gemfile/report.rb', line 9

def self.generate
  new.generate
end

Instance Method Details

#generateObject



13
14
15
16
17
18
19
20
21
# File 'lib/lock/gemfile/report.rb', line 13

def generate
  total_gems = gem_count
  local_gems = locally_available_gemspec_count
  remote_gems = remotely_available_gemspec_count

  puts "Total gems: #{total_gems}"
  puts "Matching gems locally available: #{local_gems} (#{pct_of(local_gems - total_gems, total_gems)} extra)"
  puts "Matching gems remotely available: #{remote_gems} (#{pct_of(remote_gems - total_gems, total_gems)} extra)"
end