From c1f23cf13d7e41345df2816930fd9dc9447e5697 Mon Sep 17 00:00:00 2001 From: Ramon Roche Date: Thu, 5 Jun 2025 11:51:34 -0700 Subject: [PATCH] ci: only run on pull request * runs all scripts * runs on the exact commit not the merge commit Signed-off-by: Ramon Roche --- .github/workflows/docs_metadata_check.yml | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/.github/workflows/docs_metadata_check.yml b/.github/workflows/docs_metadata_check.yml index b9a0ad3572..410adbfc4f 100644 --- a/.github/workflows/docs_metadata_check.yml +++ b/.github/workflows/docs_metadata_check.yml @@ -5,14 +5,10 @@ permissions: on: pull_request: {} - push: - branches: - - main - - 'release/**' jobs: metadata-check: - name: ${{ matrix.name }} metadata + name: ${{ matrix.name }} runs-on: [runs-on,runner=2cpu-linux-x64,image=ubuntu24-full-x64,"run-id=${{ github.run_id }}",spot=true] container: image: ghcr.io/px4/px4-dev:v1.16.0-ondemand @@ -22,8 +18,8 @@ jobs: include: - name: uORB Graphs script: Tools/ci/metadata_uorb_graph.sh - # - name: Failsafe Web - # script: Tools/ci/metadata_failsafe_web.sh + - name: Failsafe Web + script: Tools/ci/metadata_failsafe_web.sh - name: uORB Messages script: Tools/ci/metadata_msg_docs.sh - name: Parameter Reference @@ -36,6 +32,8 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 with: + ref: ${{ github.event.pull_request.head.sha }} + fetch-depth: 0 persist-credentials: true - name: Mark all directories safe for Git @@ -43,7 +41,3 @@ jobs: - name: Run ${{ matrix.name }} metadata check run: ${{ matrix.script }} --test-only - - - name: Setup tmate session - if: ${{ failure() }} - uses: mxschmitt/action-tmate@v3