Skip to content

Updates for file translationfiles/templates/certificate24.pot in fr_FR #46

Updates for file translationfiles/templates/certificate24.pot in fr_FR

Updates for file translationfiles/templates/certificate24.pot in fr_FR #46

Workflow file for this run

name: build-l10n
on:
pull_request:
paths:
- '.github/workflows/build-l10n.yml'
- 'translationfiles/*/*.po'
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
name: translations
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Install dependencies
run: |
sudo apt-get -y update
sudo apt-get -y install gettext
- name: Build translations
run: |
make build-l10n
- name: Commit changes
run: |
CHECKOUT_SHA=$(git rev-parse HEAD)
echo "Checked out $CHECKOUT_SHA"
if [ "$CHECKOUT_SHA" != "${{github.event.pull_request.head.sha}}" ]; then
echo "More changes since this commit ${{github.event.pull_request.head.sha}}, skipping"
else
git add l10n/*.js l10n/*.json
CHANGES=$(git status --porcelain)
if [ -z "$CHANGES" ]; then
echo "No files have changed, no need to commit / push."
else
git config user.name "$(git log -n 1 --pretty=format:%an)"
git config user.email "$(git log -n 1 --pretty=format:%ae)"
git commit -m "Update l10n files from ${{github.event.pull_request.head.sha}}" l10n/*
git push
fi
fi