mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
47 lines
1.1 KiB
YAML
47 lines
1.1 KiB
YAML
name: Run the po generator script
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- dev
|
|
|
|
jobs:
|
|
build:
|
|
if: github.repository == 'wavelog/wavelog'
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
repository: wavelog/wavelog
|
|
ref: dev
|
|
|
|
- name: Set up gettext
|
|
run: sudo apt-get install -y gettext
|
|
|
|
- name: Run all po_gen scripts
|
|
run: |
|
|
./po_gen.sh
|
|
./install/po_gen_installer.sh
|
|
|
|
- name: Commit changes
|
|
run: |
|
|
git config --global user.name "github-actions"
|
|
git config --global user.email "github-actions@github.com"
|
|
git add .
|
|
git commit -m "po/mo updates"
|
|
git push
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Command Weblate to perform a pull
|
|
env:
|
|
WEBLATE_TOKEN: ${{ secrets.WEBLATE_TOKEN }}
|
|
WEBLATE_URL: ${{ secrets.WEBLATE_URL }}
|
|
run: |
|
|
sleep 2
|
|
curl --silent \
|
|
-d operation=pull \
|
|
-H "Authorization: Token $WEBLATE_TOKEN" \
|
|
$WEBLATE_URL |