diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 71c751d..a10f32d 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,11 +1,12 @@ name: Publish on: - pull_request: push: branches: - main workflow_dispatch: + pull_request: + merge_group: jobs: docker: @@ -14,12 +15,12 @@ jobs: steps: - uses: docker/setup-buildx-action@v3 - uses: docker/login-action@v3 - if: github.event_name != 'pull_request' + if: github.ref_name == 'main' with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - uses: docker/build-push-action@v5 with: - push: ${{ github.event_name != 'pull_request' }} + push: ${{ github.ref_name == 'main' }} tags: ghcr.io/hermit-os/hermit-toolchain:latest