From 0461c87ddde1e47eb7a33d64bcc7a42175e46023 Mon Sep 17 00:00:00 2001 From: "Build A (factory)" Date: Sat, 5 Dec 2026 21:39:00 -0500 Subject: [PATCH] INT-597: ci: run dead-code and product validation on pushes to main --- .github/workflows/dead-code.yml | 4 +++- .github/workflows/product-validation.yml | 9 ++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/dead-code.yml b/.github/workflows/dead-code.yml index 75a5798..39d1aa5 100644 --- a/.github/workflows/dead-code.yml +++ b/.github/workflows/dead-code.yml @@ -2,6 +2,8 @@ name: Dead code # Managed by CodexSkills bootstrap-code-quality.py on: pull_request: + push: + branches: [main] permissions: contents: read jobs: @@ -14,4 +16,4 @@ jobs: - uses: astral-sh/setup-uv@v7 - run: bash scripts/check-dead-code.sh env: - QUALITY_BASE_REF: origin/${{ github.base_ref }} + QUALITY_BASE_REF: ${{ github.event_name == 'pull_request' && format('origin/{0}', github.base_ref) || github.event.before != '0000000000000000000000000000000000000000' && github.event.before || '' }} diff --git a/.github/workflows/product-validation.yml b/.github/workflows/product-validation.yml index e375bec..fca2645 100644 --- a/.github/workflows/product-validation.yml +++ b/.github/workflows/product-validation.yml @@ -1,5 +1,8 @@ name: Product validation -on: [pull_request] +on: + pull_request: + push: + branches: [main] permissions: contents: read jobs: @@ -8,13 +11,13 @@ jobs: steps: - uses: actions/checkout@v7 with: - ref: ${{ github.event.pull_request.head.sha }} + ref: ${{ github.event.pull_request.head.sha || github.sha }} - uses: astral-sh/setup-uv@v7 - run: uv sync --locked - run: uv run --locked python scripts/validate.py - uses: actions/upload-artifact@v7 if: always() with: - name: simbrief-validation-${{ github.event.pull_request.head.sha }} + name: simbrief-validation-${{ github.event.pull_request.head.sha || github.sha }} path: artifacts/validation/ if-no-files-found: error