GitHub action setup

The autoglot GitHub action automatically translates your .xcstrings files whenever they change and creates a PR with the translations.

Basic setup

Create a workflow file at .github/workflows/translate.yml:

yaml
name: Translate

on:
  push:
    branches: [main]
    paths: ['**/*.xcstrings']

jobs:
  translate:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - uses: autoglot/action@v2
        with:
          api-key: ${{ secrets.AUTOGLOT_API_KEY }}
          languages: 'de,fr,ja,es'

Add your API key

  1. Go to your repository Settings → Secrets → Actions
  2. Click "New repository secret"
  3. Name: AUTOGLOT_API_KEY
  4. Value: Your API key from the dashboard