From 7b5e25766dbdc02c408c12838f98d05ecb383130 Mon Sep 17 00:00:00 2001 From: Dennis Ploetner Date: Tue, 1 Dec 2026 11:57:35 +0100 Subject: [PATCH] Publish built plugin to a build branch Builds the shippable plugin with the existing build-plugin action and force-pushes it as a fresh history to `build`, so a server can deploy and test it with git before a release. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/build-branch.yml | 37 ++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/build-branch.yml diff --git a/.github/workflows/build-branch.yml b/.github/workflows/build-branch.yml new file mode 100644 index 00000000..50c78b9c --- /dev/null +++ b/.github/workflows/build-branch.yml @@ -0,0 +1,37 @@ +name: Publish build branch + +# Builds the shippable plugin and force-pushes it as a fresh history to the +# `build` branch, so a server can deploy it with git (see update-ploetner.sh). +# Run manually on any branch to test that branch's build. +on: + push: + branches: + - master + workflow_dispatch: + +permissions: + contents: write + +concurrency: + group: build-branch + cancel-in-progress: true + +jobs: + build: + name: Build and publish to build + runs-on: ubuntu-latest + steps: + - name: Checkout project + uses: actions/checkout@v7 + - name: Build plugin + id: build + uses: ./.github/actions/build-plugin + - name: Publish to build + run: | + cd "${{ steps.build.outputs.build-dir }}" + git init -q -b build + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github.com" + git add -A + git commit -q -m "Build ${GITHUB_SHA::7} from ${GITHUB_REF_NAME}" + git push -f "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git" build