-
Notifications
You must be signed in to change notification settings - Fork 7
44 lines (34 loc) · 1.32 KB
/
deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: CD
on:
# Triggers the workflow on push or pull request events but only for the main branch
schedule:
- cron: '0 */12 * * *'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
uses: actions/checkout@v2
- name: Setup python
uses: actions/setup-python@v2
with:
python-version: '3.9'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Config Transifex client
run: |
tx init --token=${{ secrets.TRANSIFEX_TOKEN }} --force --no-interactive
tx config mapping -r persian-pep8.build-gettext-index-pot--main --source-lang en --type PO --source-file _build/gettext/index.pot --expression 'locale/<lang>/LC_MESSAGES/index.po' --minimum-perc 1 --execute
- name: Pull translations
run: tx pull --all --force --no-interactive --mode reviewed
- name: Commit files to the repo
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: 'Auto translations commit'
branch: main
file_pattern: locale/fa/LC_MESSAGES/*.po
status_options: '--untracked-files=no'