b8a6a8c8ce
Co-authored-by: Eric Bailey <git@esb.lol> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
48 lines
1.7 KiB
YAML
48 lines
1.7 KiB
YAML
name: Nightly Update Source Languages
|
|
on:
|
|
schedule:
|
|
- cron: "0 2 * * *" # run at 2 AM UTC
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
extract-languages:
|
|
name: Nightly Update Source Languages
|
|
runs-on: ubuntu-latest
|
|
|
|
permissions:
|
|
# Give the default GITHUB_TOKEN write permission to commit and push the
|
|
# added or changed files to the repository.
|
|
contents: write
|
|
|
|
steps:
|
|
- name: Check out Git repository
|
|
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
|
|
with:
|
|
ssh-key: ${{secrets.GH_ACTION_DEPLOY_KEY}}
|
|
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
|
|
- name: Install node
|
|
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
|
|
with:
|
|
node-version-file: package.json
|
|
cache: pnpm
|
|
- name: pnpm install
|
|
run: pnpm install --frozen-lockfile
|
|
- name: Extract language strings
|
|
run: pnpm intl:extract
|
|
- name: Create commit
|
|
uses: stefanzweifel/git-auto-commit-action@04702edda442b2e678b25b537cec683a1493fcb9 # v7.1.0
|
|
with:
|
|
commit_message: Nightly source-language update
|
|
file_pattern: ./src/locale/locales/en/messages.po
|
|
- name: Push source lang to Crowdin
|
|
uses: crowdin/github-action@52aa776766211d83d975df51f3b9c53c2f8ba35f # v2.16.3
|
|
with:
|
|
upload_sources: true
|
|
upload_sources_args: "-b main"
|
|
upload_translations: false
|
|
push_translations: false
|
|
push_sources: false
|
|
create_pull_request: false
|
|
env:
|
|
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
|