Skip to content

Fix naive pluralization in scaffolding tools - #942

Open
mandre wants to merge 1 commit into
k-orc:mainfrom
shiftstack:scaffolding-pluralisation
Open

mandre wants to merge 1 commit into
k-orc:mainfrom
shiftstack:scaffolding-pluralisation

Conversation

@mandre

@mandre mandre commented Sep 25, 2026

Copy link
Copy Markdown
Collaborator

Replace all naive "+s" plural suffixes in scaffold-controller and resource-generator templates with a pluralize() function that handles common English rules:

  • Consonant + y → ies (e.g. Policy → Policies)
  • Sibilant endings (s, sh, ch, x, z) → es
  • Default → s

This prevents incorrect forms like "qospolicys" when scaffolding resources whose names don't simply take an s.

@mandre mandre mentioned this pull request Sep 25, 2026
@github-actions github-actions Bot added the semver:patch No API change label Sep 25, 2026
Replace all naive "+s" plural suffixes in scaffold-controller
and resource-generator templates with a pluralize() function
that handles common English rules:

- Consonant + y → ies (e.g. Policy → Policies)
- Sibilant endings (s, sh, ch, x, z) → es
- Default → s

This prevents incorrect forms like "qospolicys" when
scaffolding resources whose names don't simply take an s.
@mandre
mandre force-pushed the scaffolding-pluralisation branch from 455d41e to 126f97c Compare September 27, 2026 11:55

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver:patch No API change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant