You can run the POEditor CLI in any CI pipeline, such as GitHub Actions, GitLab CI, Bitbucket Pipelines or Jenkins. Common jobs are:
- pull before a build, so every build ships the latest translations;
- push on the main branch, so new strings reach translators as soon as they are merged;
-
a scheduled pull that opens a pull request with new translations.
What you need
.poeditor.ymlcommitted in your repository. See How to set up the .poeditor.yml file for CLI.- A POEditor API token saved as a secret in your CI. Copy it from your account's API access page.
How to give the CLI your token
In CI, you don't run poeditor auth login. Pass the token in an environment variable instead:
| Variable | Token for |
|---|---|
POEDITOR_TOKEN |
the default account |
POEDITOR_TOKEN_<ACCOUNT> |
a named account from .poeditor.yml, upper-cased, with - written as _. For client-a, use POEDITOR_TOKEN_CLIENT_A. |
Nothing is stored on the CI machine. More about tokens and accounts: CLI login and API tokens.
Use the least access you need. A read-only token is enough for a job that only runs pull or config check. push and any command that changes POEditor need a token with full access.
How to install the CLI in CI
Use the install script, with a fixed version so a new release can't change your build unannounced:
curl -fsSL https://raw.githubusercontent.com/POEditor/poeditor-cli/master/install.sh | POEDITOR_VERSION=v0.1.0 POEDITOR_INSTALL_DIR="$HOME/.local/bin" sh
Replace v0.1.0 with the version you want. The script needs curl or wget, and checks the download against the release's checksums. POEDITOR_INSTALL_DIR puts the binary in a folder the job can always write to; add that folder to the PATH, as the examples below show. On Windows runners, use install.ps1 the same way:
$env:POEDITOR_VERSION = 'v0.1.0'
irm https://raw.githubusercontent.com/POEditor/poeditor-cli/master/install.ps1 | iex
If your CI image has Go 1.27 or later, you can use go install github.com/POEditor/poeditor-cli/cmd/poeditor@v0.1.0 instead. For other ways to install the CLI, see CLI quick start.
Start every job with config check
poeditor config check
It fails the job if .poeditor.yml names a project, language or account that doesn't exist, or if a token is missing, before any file is changed.
Note: the GitHub Actions and GitLab CI steps in this article match their documentation as of November 2026. See GitHub's Events that trigger workflows and Using secrets in GitHub Actions, and GitLab's CI/CD variables.
GitHub Actions: pull before a build
Add these steps to your build job, after the step that checks out your repository:
- name: Install poeditor
run: |
curl -fsSL https://raw.githubusercontent.com/POEditor/poeditor-cli/master/install.sh | POEDITOR_VERSION=v0.1.0 POEDITOR_INSTALL_DIR="$HOME/.local/bin" sh
echo "$HOME/.local/bin" >> "$GITHUB_PATH"
- name: Pull translations
run: poeditor config check && poeditor pull
env:
POEDITOR_TOKEN: ${{ secrets.POEDITOR_TOKEN }}
GitHub Actions: push new strings from the main branch
on:
push:
branches: [main]
jobs:
push-strings:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install poeditor
run: |
curl -fsSL https://raw.githubusercontent.com/POEditor/poeditor-cli/master/install.sh | POEDITOR_VERSION=v0.1.0 POEDITOR_INSTALL_DIR="$HOME/.local/bin" sh
echo "$HOME/.local/bin" >> "$GITHUB_PATH"
- run: poeditor config check && poeditor push
env:
POEDITOR_TOKEN: ${{ secrets.POEDITOR_TOKEN }}
GitHub Actions: a scheduled pull that opens a pull request
This workflow pulls translations every Monday at 06:00 UTC and opens a pull request only when something changed. Change the cron value to suit your release rhythm. Scheduled workflows run in UTC, on the latest commit of your default branch, and workflow_dispatch also lets you start the workflow by hand from the Actions tab.
Because the workflow creates a pull request, turn on Allow GitHub Actions to create and approve pull requests in your repository, under Settings > Actions > General > Workflow permissions. Repositories in an organization inherit the organization's setting. See Managing GitHub Actions settings for a repository.
name: Pull translations
on:
schedule:
- cron: "0 6 * * 1"
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
pull-translations:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install poeditor
run: |
curl -fsSL https://raw.githubusercontent.com/POEditor/poeditor-cli/master/install.sh | POEDITOR_VERSION=v0.1.0 POEDITOR_INSTALL_DIR="$HOME/.local/bin" sh
echo "$HOME/.local/bin" >> "$GITHUB_PATH"
- name: Pull translations
run: poeditor config check && poeditor pull
env:
POEDITOR_TOKEN: ${{ secrets.POEDITOR_TOKEN }}
- name: Open a pull request
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
if [ -z "$(git status --porcelain)" ]; then
echo "No new translations."
exit 0
fi
branch="translations-$(date +%Y-%m-%d)"
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git checkout -b "$branch"
git add -A
git commit -m "Update translations from POEditor"
git push origin "$branch"
gh pr create --title "Update translations from POEditor" --body "New translations pulled with the POEditor CLI."
GitLab CI: pull before a build
pull-translations:
stage: build
script:
- curl -fsSL https://raw.githubusercontent.com/POEditor/poeditor-cli/master/install.sh | POEDITOR_VERSION=v0.1.0 POEDITOR_INSTALL_DIR="$HOME/.local/bin" sh
- export PATH="$HOME/.local/bin:$PATH"
- poeditor config check
- poeditor pull
variables:
POEDITOR_TOKEN: $POEDITOR_TOKEN
Add POEDITOR_TOKEN under Settings > CI/CD > Variables, and mark it as masked.
Several accounts
If .poeditor.yml uses more than one account, set one variable per account. In GitHub Actions, for example:
env:
POEDITOR_TOKEN: ${{ secrets.POEDITOR_TOKEN }}
POEDITOR_TOKEN_CLIENT_A: ${{ secrets.POEDITOR_TOKEN_CLIENT_A }}
Things to know
Exit codes. Every command exits with an error when it fails, so the CI job fails too. pull and push stop at the first file that fails and name it.
Uploads take time. POEditor accepts one upload every 10 seconds (20 on the Free plan), and push waits between files. A push with many files can take a few minutes. That's expected. See POEditor API rates and limitations for all limits.
pull doesn't create noise. Files whose content didn't change aren't rewritten, so a job that commits the result only has changes to commit when translations changed.
Readable logs. On a CI machine, commands that show data print tab-separated lines instead of tables, and progress goes to stderr. Add --json if a later step reads the output.