Integrate the Transifex CLI within a Github action. Usage:
-
Make sure your repository has a Transifex CLI configuration. If not, set it up with:
tx init tx add # Complete the interactive wizard git add .tx git commit -m "Add Transifex CLI configuration"
-
Add a Transifex API token to your repository as a repository secret
-
Use this in your Github action workflow:
on: [push] jobs: Push-source-file: runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v2 - name: Push source file using transifex client uses: transifex/cli-action@v2 with: token: ${{ secrets.TX_TOKEN }}
token
(required): The Transifex API token to use for pushing
version
(default: latest): The Transifex CLI version to use
args
(default: push): Which arguments to pass to the tx command. By
default, the CLI will push the source files of all resources configured in
.tx/config
.