You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
46 lines
1.6 KiB
46 lines
1.6 KiB
name: Sync Localazy |
|
on: |
|
workflow_dispatch: |
|
schedule: |
|
# At 00:00 on every Monday UTC |
|
- cron: '0 0 * * 1' |
|
|
|
jobs: |
|
sync-localazy: |
|
runs-on: ubuntu-latest |
|
# Skip in forks |
|
if: github.repository == 'element-hq/element-x-android' |
|
steps: |
|
- uses: actions/checkout@v4 |
|
- name: Use JDK 17 |
|
uses: actions/setup-java@v4 |
|
with: |
|
distribution: 'temurin' # See 'Supported distributions' for available options |
|
java-version: '17' |
|
- name: Configure gradle |
|
uses: gradle/actions/setup-gradle@v3 |
|
with: |
|
cache-read-only: ${{ github.ref != 'refs/heads/develop' }} |
|
- name: Set up Python 3.9 |
|
uses: actions/setup-python@v5 |
|
with: |
|
python-version: 3.9 |
|
- name: Setup Localazy |
|
run: | |
|
curl -sS https://dist.localazy.com/debian/pubkey.gpg | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/localazy.gpg |
|
echo "deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/localazy.gpg] https://maven.localazy.com/repository/apt/ stable main" | sudo tee /etc/apt/sources.list.d/localazy.list |
|
sudo apt-get update && sudo apt-get install localazy |
|
- name: Run Localazy script |
|
run: | |
|
./tools/localazy/downloadStrings.sh --all |
|
./tools/test/generateAllScreenshots.py |
|
- name: Create Pull Request for Strings |
|
uses: peter-evans/create-pull-request@v6 |
|
with: |
|
token: ${{ secrets.DANGER_GITHUB_API_TOKEN }} |
|
commit-message: Sync Strings from Localazy |
|
title: Sync Strings |
|
body: | |
|
- Update Strings from Localazy |
|
branch: sync-localazy |
|
base: develop
|
|
|