From 02c98a8e8ec43780033d7099f19c5b89efc0a548 Mon Sep 17 00:00:00 2001 From: Markus Unterwaditzer Date: Sat, 14 Jun 2025 02:10:56 +0200 Subject: [PATCH] Do not publish docs from any branch Documentation was being pushed from an unrelated PR that I opened, because that PR was created from a branch pushed to efforg instead of my own fork. --- .github/workflows/main.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 105ff57..2280fda 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -2,8 +2,9 @@ name: main on: push: + branches: [ main ] pull_request: - workflow_call: + branches: [ main ] env: CARGO_TERM_COLOR: always @@ -65,7 +66,7 @@ jobs: mdbook_publish: name: Publish mdBook to Github Pages needs: mdbook_test - if: ${{ github.event_name != 'pull_request' }} + if: ${{ github.ref == 'refs/heads/main' }} permissions: pages: write contents: write