Module: RailsContributorGenders
- Defined in:
- lib/rails_contributor_genders.rb,
lib/rails_contributor_genders/version.rb
Constant Summary collapse
- VERSION =
"0.1.1"
Class Method Summary collapse
Class Method Details
.results(number = nil) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/rails_contributor_genders.rb', line 6 def self.results(number = nil) all_names = Importer.new.contributor_names names = if number all_names.first(number.to_i) else all_names end results = Analyzer.new(names).results results[:neutral] = results.delete(:andy) results.each_pair do |gender, count| puts "#{gender.to_s.capitalize.gsub("_", " ")}: #{count}" end nil end |