diff --git a/.github/workflows/check-review-md.yml b/.github/workflows/check-review-md.yml index fb093ac9a1..4efa5edfc3 100644 --- a/.github/workflows/check-review-md.yml +++ b/.github/workflows/check-review-md.yml @@ -14,7 +14,10 @@ concurrency: jobs: audit: + # Set the ENABLE_CLAUDE_CODE repository variable to 'false' to turn off Claude + # jobs; leave it unset (the default) to keep them enabled. if: >- + vars.ENABLE_CLAUDE_CODE != 'false' && github.event.pull_request.draft == false && github.event.pull_request.head.repo.full_name == github.repository runs-on: ubuntu-latest diff --git a/.github/workflows/claude-md-audit.yml b/.github/workflows/claude-md-audit.yml index 32240ba5ea..e6d459fd9b 100644 --- a/.github/workflows/claude-md-audit.yml +++ b/.github/workflows/claude-md-audit.yml @@ -15,7 +15,10 @@ concurrency: jobs: audit: + # Set the ENABLE_CLAUDE_CODE repository variable to 'false' to turn off Claude + # jobs; leave it unset (the default) to keep them enabled. if: >- + vars.ENABLE_CLAUDE_CODE != 'false' && github.event.pull_request.draft == false && github.event.pull_request.head.repo.full_name == github.repository runs-on: ubuntu-latest diff --git a/.github/workflows/claude.yml b/.github/workflows/claude.yml index 1c783e7ef6..6eb3ec9e86 100644 --- a/.github/workflows/claude.yml +++ b/.github/workflows/claude.yml @@ -12,11 +12,16 @@ on: jobs: claude: + # Set the ENABLE_CLAUDE_CODE repository variable to 'false' to turn off Claude + # jobs; leave it unset (the default) to keep them enabled. if: | - (github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) || - (github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) || - (github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude')) || - (github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude'))) + vars.ENABLE_CLAUDE_CODE != 'false' && + ( + (github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) || + (github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) || + (github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude')) || + (github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude'))) + ) runs-on: ubuntu-latest permissions: contents: write diff --git a/.github/workflows/workflow-checks.yml b/.github/workflows/workflow-checks.yml index a11918c04f..e99a4d3342 100644 --- a/.github/workflows/workflow-checks.yml +++ b/.github/workflows/workflow-checks.yml @@ -36,6 +36,11 @@ jobs: zizmor: name: Zizmor + # Uploads SARIF to the Security tab, which requires GitHub code scanning to be + # enabled on the repository. Set the ENABLE_WORKFLOW_SECURITY_SCAN repository + # variable to 'false' to skip this job where code scanning isn't available; + # leave it unset (the default) to run the scan. + if: ${{ vars.ENABLE_WORKFLOW_SECURITY_SCAN != 'false' }} runs-on: ubuntu-latest permissions: security-events: write # Upload SARIF to GitHub Security tab