ci: gate optional Claude and security-scan jobs behind repository variables#3901
ci: gate optional Claude and security-scan jobs behind repository variables#3901d-cs wants to merge 1 commit into
Conversation
…iables Add per-job `if:` gates so deployments that don't want or can't run these jobs can switch them off without editing workflows: - ENABLE_CLAUDE_CODE gates the Claude jobs (interactive @claude, the CLAUDE.md audit, and the REVIEW.md drift audit). - ENABLE_WORKFLOW_SECURITY_SCAN gates the Zizmor job, which uploads SARIF and so needs GitHub code scanning enabled. Both default to enabled: a job runs unless its variable is explicitly set to 'false', so existing behaviour is unchanged where the variables are unset.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📜 Recent review details⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🧰 Additional context used🧠 Learnings (1)📚 Learning: 2026-05-12T14:34:38.795ZApplied to files:
🔇 Additional comments (4)
WalkthroughThis PR adds repository variable guards to control the execution of GitHub Actions workflow jobs. The ENABLE_CLAUDE_CODE variable is added to three Claude Code-related workflows (check-review-md.yml, claude-md-audit.yml, and claude.yml) to skip those jobs when the variable is set to 'false'. A separate ENABLE_WORKFLOW_SECURITY_SCAN variable is added to the zizmor job in workflow-checks.yml for the same purpose. All guards follow the same pattern: jobs run by default unless the variable is explicitly set to 'false'. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Add per-job
if:gates so deployments that don't want — or can't run — these jobs can switch them off via repository variables, without editing workflows.ENABLE_CLAUDE_CODEgates the Claude jobs: interactive@claude, the CLAUDE.md audit, and the REVIEW.md drift audit.ENABLE_WORKFLOW_SECURITY_SCANgates the Zizmor job, which uploads SARIF and so needs GitHub code scanning enabled.Both default to enabled: a job runs unless its variable is explicitly set to
'false', so behaviour is unchanged anywhere the variables are unset. The siblingactionlintjob and the report-only Trivy scan are untouched.Test plan
actionlintclean on the four edited workflows