From b3287c0d87c511013b9ffb23bf74fc6320c5abf1 Mon Sep 17 00:00:00 2001 From: Ashley Date: Mon, 9 Oct 2023 16:53:39 +0100 Subject: [PATCH 1/2] Add workflow to compile translations This adds a workflow that compiles translations when changes are pushed to the "translations" branch. The workflow installs dependencies for the frontend, compiles the translations, and commits and pushes the changes to the "translations" branch. --- .github/workflows/translations.yml | 47 ++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 .github/workflows/translations.yml diff --git a/.github/workflows/translations.yml b/.github/workflows/translations.yml new file mode 100644 index 000000000..a8f0ce6a7 --- /dev/null +++ b/.github/workflows/translations.yml @@ -0,0 +1,47 @@ +name: Compile Translations + +on: + push: + branches: + - translations + workflow_dispatch: {} + +permissions: + packages: write + +jobs: + compile: + runs-on: ubuntu-latest + steps: + # Checkout the repo and the translations branch + - name: Checkout + uses: actions/checkout@v2 + with: + ref: translations + + # Install dependencies node and npm + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y nodejs npm + + # Install dependencies for frontend + - name: Install dependencies for frontend + run: | + cd frontend + npm install + + # Compile translations + - name: Compile translations + run: | + cd frontend + npm run gettext:compile + + # Commit and push changes + - name: Commit and push changes + run: | + git config --local user.name "GitHub Action" + git config --local user.email "<>" + git add ./src/language/translations.json + git commit -m "Compile translations" + git push origin translations From 0bd499bb8df4f6fa5a0b72e4c7581842817f7169 Mon Sep 17 00:00:00 2001 From: Ashley Date: Mon, 9 Oct 2023 17:05:59 +0100 Subject: [PATCH 2/2] refactor: Simplify supported platforms in CI workflows This change updates the CI workflows to only support the linux/amd64 and linux/arm64 platforms, removing support for linux/arm64/v7 and linux/arm64/v8. This simplification reduces complexity and streamlines the CI process. --- .github/workflows/beta-ci.yml | 2 +- .github/workflows/ci.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/beta-ci.yml b/.github/workflows/beta-ci.yml index 1e8906cdd..946213ff8 100644 --- a/.github/workflows/beta-ci.yml +++ b/.github/workflows/beta-ci.yml @@ -49,5 +49,5 @@ jobs: tags: | ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.IMAGE_TAG }} ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.IMAGE_TAG }}-${{ steps.get_version.outputs.version }} - platforms: linux/amd64,linux/arm64,linux/arm64/v7,linux/arm64/v8 + platforms: linux/amd64,linux/arm64 provenance: false diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 90be4d0a1..795d9b369 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -49,7 +49,7 @@ jobs: context: . file: ./Dockerfile push: true - platforms: linux/amd64,linux/arm64,linux/arm64/v7,linux/arm64/v8 + platforms: linux/amd64,linux/arm64 provenance: false tags: | ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest