I want to create a pluralization rule for some terms that aren't correctly pluralized. I'll place it on my inflections.rb file.
The terms are some compound ones that I may pluralize the first word, instead of the second, but, in my case, I don't have the option to apply the pluralize function on the first term only. For example:
'base of knowledge'.pluralize
should return 'bases of knowledge'
instead of 'base of knowledges'
I tried a regexp like this one /\sof\s/
to find the of
part on the string, but could't write a rule to inflect correctly.
inflect.plural(???, ???)
Obs: I'm not looking for a linguistic workaround, like 'knowledge base'. The example is merely illustrative.