sonic-pi

https://github.com/sonic-pi-net/sonic-pi

C++

Code. Music. Live.

I18n::Backend::Base#pluralize

Picks a translation from a pluralized mnemonic subkey according to English
pluralization rules :
- It will pick the :one subkey if count is equal to 1.
- It will pick the :other subkey otherwise.
- It will pick the :zero subkey in the special case where count is
  equal to 0 and there is a :zero subkey present. This behaviour is
  not stand with regards to the CLDR pluralization rules.
Other backends can implement more flexible or complex pluralization rules.

Source | Google | Stack overflow

Edit

git clone [email protected]:sonic-pi-net/sonic-pi.git

cd sonic-pi

open app/server/ruby/vendor/i18n-1.14.1/lib/i18n/backend/base.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-I18n--Backend--Base-pluralize-for-pr


# Commit to git

git add app/server/ruby/vendor/i18n-1.14.1/lib/i18n/backend/base.rbgit commit -m "better docs for I18n::Backend::Base#pluralize"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-I18n--Backend--Base-pluralize-for-pr

hub pull-request


# Celebrate!