moulinette/.github/workflows/i18n.yml
OniriCorpe 1b28bca0c0 chores: update actions to nodejs 20
Also replaces rickstaa/action-black by psf/black
2024-03-07 01:39:48 +01:00

29 lines
934 B
YAML

name: Autoreformat locale files
on:
push:
branches:
- dev
jobs:
i18n:
name: Autoreformat locale files
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Apply reformating scripts
id: action_reformat
run: |
python3 test/remove_stale_i18n_strings.py
python3 test/autofix_locale_format.py
python3 test/reformat_locales.py
git diff -w --exit-code
- name: Create Pull Request
if: ${{ failure() }}
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
title: "Reformat locale files"
commit-message: ":robot: Reformat locale files"
body: |
Automatic pull request using the scripts in `test/`
base: ${{ github.head_ref }}
branch: actions/i18nreformat