diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e859e4613..bea5f6eb5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,11 +1,19 @@ name: Build schemas classes +# A pull request gets the tests, the build and the toolbox tests, so that a +# reviewer sees whether the generated output changes and whether the toolbox +# still passes with it. Only a push to pipeline writes the build to main. on: push: branches: - pipeline paths-ignore: - 'README.md' + pull_request: + branches: + - pipeline + paths-ignore: + - 'README.md' workflow_dispatch: jobs: @@ -139,7 +147,10 @@ jobs: name: Push updates to main runs-on: ubuntu-latest needs: [build, test-code] - if: needs.test-code.result == 'success' && needs.build.outputs.build_updated == 'true' + if: >- + github.event_name != 'pull_request' && + needs.test-code.result == 'success' && + needs.build.outputs.build_updated == 'true' steps: - name: Checkout main branch uses: actions/checkout@v6