Loading
Internationalize the moved path redirect banner
What does this MR do and why?
The redirect notice shown after visiting an old project, group, or user path was built with routable.class.to_s.titleize inside a plain heredoc, so it was never wrapped in a translation function and always rendered in English.
This replaces it with one complete translatable sentence per routable type (Project, Group, User, plus a generic fallback), using named %{old_path} / %{new_path} placeholders, and adds the new strings to locale/gitlab.pot. The English output is unchanged.
References
Closes #612312 (closed)
How to set up and validate locally
- Rename or transfer a project so a redirect route exists for its old path.
- Visit the old path. You are redirected, and the notice reads the same as before in English.
- Switch your preferred language: the notice is now picked up for translation.
Existing specs that assert the exact notice text (projects, labels, groups, milestones, users controllers) cover the unchanged English output.
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist.