Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add collect_phrases pre-commit hook; run new collect phrases #610

Merged
merged 1 commit into from
May 22, 2023

Conversation

Reckless-Satoshi
Copy link
Collaborator

What does this PR do?

This PR adds collect_phrases pre-commit hook, simplifying the frontend development pipeline as now pre-commit is in charge of collecting new phrases for translation. Given that the hook will always pretty-format the collected .json files, the first "git commit" will always fail if there are new phrases; the second one will succeed.

This PR collects all i18n phrases with the new ordered dict by @JooVLC to ensure consistent ordering cross-platform.

Checklist before merging

  • Install pre-commit and initialize it: pip install pre-commit, then pre-commit install. Pre-commit installs git hooks that automatically check the codebase. If pre-commit fails when you commit your changes, please fix the problems it points out.

@Reckless-Satoshi Reckless-Satoshi marked this pull request as ready for review May 22, 2023 08:26
@Reckless-Satoshi Reckless-Satoshi merged commit cdc5f3d into main May 22, 2023
@Reckless-Satoshi Reckless-Satoshi deleted the run-new-collect-phrases branch May 22, 2023 08:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant