Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
T
tails
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 960
    • Issues 960
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 14
    • Merge Requests 14
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • tails
  • tails
  • Issues
  • #17877

Closed
Open
Created Aug 18, 2020 by emmapeel@emmapeelDeveloper

Design and document git hook to prevent the moving of 'core pages' without updating the core pages file

The translation platform got broken the other day (sysadmin ticket #17736) because we moved some files that were listed on wiki/src/contribute/l10n_tricks/core_po_files.txt.

This file is written by the website editors with the most important pages, and read by weblate to update the component list core-pages, used by translators to prioritise their work.

While debugging this problem, @zen started writing a git pre-commit hook that would alert editors when moving a page mentioned on the core_po_files.txt file, so they can also move it on the list.

Unfortunately it needs a bit more work to be used along other pre-commit hooks we already ship.

The pre-commit hook should work when pasted along other pre-commit hooks people could have, and there is already one on the /bin/ directory of the repo to prevent problems with .po files: https://gitlab.tails.boum.org/tails/tails/-/blob/stable/bin/pre-commit-translation

It would be also good to do it in a way that we can easily plug it into our CI some day, to increase the chances this gets spotted, ideally at merge request time, worst case post-merge, so we don't rely solely on "everyone who does technical writing has a given pre-commit hook enabled".

The current version of the patch can be downloaded here and the discussion on the previous ticket (sysadmin #17736) from here onwards is relevant to this ticket.

Edited Aug 19, 2020 by emmapeel
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None