Skip to content

[Transifex] Updates for project Beyond All Reason Localization and language ru #176

[Transifex] Updates for project Beyond All Reason Localization and language ru

[Transifex] Updates for project Beyond All Reason Localization and language ru #176

# Translation workflow is:
# 1. English I18N keys/captions changed on master
# 2. master merged to transifex-synchronization-source
# 3. Transifex picks up changes on transifex-synchronization-source
# 4. Translations made on Transifex
# 5. Transifex creates pull request against transifex-synchronization-source
# Since transifex-synchronization-source is just a staging branch to
# control updates to Transifex, it is never merged to master, so we
# need to change the merge target of Transifex's pull requests to master
name: Translations set merge target to master
on:
pull_request:
types: [opened, synchronize]
branches:
- 'transifex-synchronization-source'
jobs:
auto_change_base_branch:
runs-on: ubuntu-latest
steps:
- name: Change base branch of pull request
run: |
TOKEN="${{ secrets.GITHUB_TOKEN }}"
PR_NUMBER="${{ github.event.number }}"
NEW_BASE_BRANCH="master"
URL="https://api.github.com/repos/${{ github.repository }}/pulls/${PR_NUMBER}"
DATA="{\"base\":\"${NEW_BASE_BRANCH}\"}"
curl -X PATCH -H "Authorization: token $TOKEN" -H "Accept: application/vnd.github.v3+json" -d "$DATA" "$URL"