From f5aa34bb371acd0d1f7e660ba2dfcedba9b82400 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Thu, 30 May 2024 09:56:56 -0400 Subject: [PATCH] Add GitHub action to run makemessages --- .../workflows/update-translation-strings.yml | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/update-translation-strings.yml diff --git a/.github/workflows/update-translation-strings.yml b/.github/workflows/update-translation-strings.yml new file mode 100644 index 000000000..d9aa7c3c6 --- /dev/null +++ b/.github/workflows/update-translation-strings.yml @@ -0,0 +1,35 @@ +name: Update translation strings + +on: workflow_dispatch + +permissions: + contents: read + +jobs: + makemessages: + runs-on: ubuntu-latest + env: + NETBOX_CONFIGURATION: netbox.configuration_testing + + steps: + - name: Check out repo + uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: 3.11 + + - name: Install dependencies & set up configuration + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + + - name: Run makemessages + run: python netbox/manage.py makemessages -l en + + - name: Commit changes + uses: EndBug/add-and-commit@v9 + with: + add: 'netbox/translations/' + message: 'Update source translation strings'