Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

More i18n process updates (#7720)

* Modify intl:extract to only target english, the source language

* Add github action to regularly update english .po file

* Update localization doc

authored by

Paul Frazee and committed by
GitHub
3ab5c6a7 accd1834

+44 -6
+36
.github/workflows/nightly-update-source-languages.yaml
··· 1 + name: Nightly Update Source Languages 2 + on: 3 + schedule: 4 + - cron: '0 2 * * *' # run at 2 AM UTC 5 + workflow_dispatch: 6 + 7 + jobs: 8 + extract-languages: 9 + name: Nightly Update Source Languages 10 + runs-on: ubuntu-latest 11 + 12 + permissions: 13 + # Give the default GITHUB_TOKEN write permission to commit and push the 14 + # added or changed files to the repository. 15 + contents: write 16 + 17 + steps: 18 + - name: Check out Git repository 19 + uses: actions/checkout@v3 20 + - name: Install node 21 + uses: actions/setup-node@v4 22 + with: 23 + node-version-file: .nvmrc 24 + - name: Yarn install 25 + uses: Wandalen/wretry.action@master 26 + with: 27 + command: yarn --frozen-lockfile 28 + attempt_limit: 3 29 + attempt_delay: 2000 30 + - name: Extract language strings 31 + run: yarn intl:extract 32 + - name: Create commit 33 + uses: stefanzweifel/git-auto-commit-action@v5 34 + with: 35 + commit_message: Nightly source-language update 36 + file_pattern: /src/locale/locales/en/messages.po
+7 -5
docs/localization.md
··· 40 40 41 41 Install the [Crowdin CLI](https://crowdin.github.io/crowdin-cli/). You will need to [configure your API token](https://crowdin.github.io/crowdin-cli/configuration) to access the project. 42 42 43 + ### English source-file sync with Crowdin 44 + 45 + Every night, a GitHub action will run `yarn intl:extract` to update the english `messages.po` file. This will be automatically synced with Crowdin. Crowdin should notify all subscribed users of new translations. 46 + 43 47 ### Release process 44 48 45 49 1. Pull main and create a branch. 46 50 1. Run `yarn intl:pull` to fetch all translation updates from Crowdin. 47 51 1. Create a PR, ensure the translations all look correct, and merge. 48 - 1. Merge all approved translation PRs (contributions from outside crowdin). 49 - 1. Pull main. 50 - 1. Run `yarn intl:extract` to sync the english `.po` file with the state of the app. 51 - 1. Run `yarn intl:push` to sync Crowdin with the state of the repo. 52 - 1. Commit the updated english `.po` and push to GitHub. 52 + 1. If needed: 53 + 1. Merge all approved translation PRs (contributions from outside crowdin). 54 + 1. Run `yarn intl:push` to sync Crowdin with the state of the repo. 53 55 54 56 ### Testing the translations in Crowdin 55 57
+1 -1
package.json
··· 43 43 "perf:test:results": "NODE_ENV=test flashlight report .perf/results.json", 44 44 "perf:measure": "NODE_ENV=test flashlight measure", 45 45 "intl:build": "yarn intl:extract && yarn intl:compile", 46 - "intl:extract": "lingui extract --clean", 46 + "intl:extract": "lingui extract --clean --locale en", 47 47 "intl:compile": "lingui compile", 48 48 "intl:pull": "crowdin download translations --verbose -b main", 49 49 "intl:push": "crowdin push translations --verbose -b main",