summaryrefslogtreecommitdiffstats
path: root/po/.gitattributes
AgeCommit message (Collapse)AuthorLines
2026-04-03l10n: add .gitattributes to simplify location filteringJiang Xin-0/+35
To simplify the location filtering process for l10n contributors when committing po/XX.po files, add filter attributes for selected PO files to the repository. This ensures all contributors automatically get the same filter configuration without manual setup in .git/info/attributes. The default filter (gettext-no-location) is applied to all .po files except: - Legacy, unmaintained PO files that still contain location comments. Leaving the filter off avoids index vs working-tree discrepancies for these files. The CI pipeline will report an error when future updates touch these legacy files. - Some PO files use a different filter that strips only line numbers from location comments while keeping filenames. Contributors still need to manually define the filter drivers via git-config as documented in po/README.md. Four PO files that use location filtering (po/ca.po, po/es.po, po/ga.po, po/ru.po) were batch-modified so their on-disk format matches the filter output (e.g. line wrapping), avoiding index vs working-tree mismatch. Additionally, po/README.md has been reorganized: the material on preparing location-less PO files for commit has been moved from "Updating a XX.po file" to a separate "Preparing a XX.po file for commit" section. This prevents AI agents from introducing unrelated operations when updating PO files. Signed-off-by: Jiang Xin <worldhello.net@gmail.com>