Sha256: aa1c48fb920a1150e0f01b6fd4430ddf0ca2a7cbaf46a6c1d4976ce2cd4ad69f

Contents?: true

Size: 656 Bytes

Versions: 17

Compression:

Stored size: 656 Bytes

Contents

module Inflections
  ActiveSupport::Inflector.inflections do |inflect|
    inflect.clear
    
    inflect.plural(/$/, 's')
    inflect.plural(/([sxz]|[cs]h)$/i, '\1es')
    inflect.plural(/([^aeiouy]o)$/i, '\1es')
    inflect.plural(/([^aeiouy])y$/i, '\1ies')
    
    inflect.singular(/s$/i, '')
    inflect.singular(/(ss)$/i, '\1')
    inflect.singular(/([sxz]|[cs]h)es$/, '\1')
    inflect.singular(/([^aeiouy]o)es$/, '\1')
    inflect.singular(/([^aeiouy])ies$/i, '\1y')
    
    inflect.irregular('child', 'children')
    inflect.irregular('person', 'people')
    inflect.irregular('self', 'selves')
    
    inflect.uncountable(%w(series))
  end
end

Version data entries

17 entries across 10 versions & 1 rubygems

Version Path
inflections-3.2.12.20130314 lib/inflections/en-GB.rb
inflections-3.2.12.20130314 lib/inflections/en.rb
inflections-3.2.12.20130305 lib/inflections/en.rb
inflections-3.2.12.20130305 lib/inflections/en-GB.rb
inflections-3.2.12 lib/inflections/en-GB.rb
inflections-3.2.12 lib/inflections/en.rb
inflections-3.2.11 lib/inflections/en-GB.rb
inflections-3.2.11 lib/inflections/en.rb
inflections-3.2.9.20121206 lib/inflections/en.rb
inflections-3.2.9.20121206 lib/inflections/en-GB.rb
inflections-3.2.9.20121201 lib/inflections/en-GB.rb
inflections-3.2.9.20121201 lib/inflections/en.rb
inflections-3.2.8 lib/inflections/en.rb
inflections-3.2.8 lib/inflections/en-GB.rb
inflections-3.2.7.20120803 lib/inflections/en.rb
inflections-0.0.5 lib/inflections/en.rb
inflections-0.0.4 lib/inflections/en.rb