Skip to content

Add zizmor GitHub Actions static analysis - #176

Merged
blarghmatey merged 2 commits into
mainfrom
worktree-add-zizmor
Aug 5, 2026
Merged

Add zizmor GitHub Actions static analysis#176
blarghmatey merged 2 commits into
mainfrom
worktree-add-zizmor

Conversation

@blarghmatey

Copy link
Copy Markdown
Member

What are the relevant tickets?

N/A

Description (What does it do?)

Adds zizmor static analysis for GitHub Actions workflows, matching the pattern rolled out across other mitodl app repos this week:

  • New .github/workflows/actions-static-analysis.yml workflow that runs zizmorcore/zizmor-action against .github/workflows/ on any push/PR touching workflow files, gated at min-severity: high / min-confidence: medium.
  • New zizmor hook in prek.toml (via zizmorcore/zizmor-pre-commit, v1.29.0) so the same checks run locally at commit time, with matching thresholds (--min-severity=high --min-confidence=medium).

No existing workflow files needed changes — a local zizmor run against the current .github/workflows/ tree at these thresholds reports no findings.

Screenshots (if appropriate):

N/A

How can this be tested?

  • prek run --files .github/workflows/actions-static-analysis.yml prek.toml — all hooks pass, including the new zizmor hook.
  • uvx zizmor@1.29.0 --no-progress --min-severity=high --min-confidence=medium .github/workflows/ — reports "No findings to report."
  • After merge, the new GitHub Actions Static Analysis workflow will run on any future PR that touches .github/workflows/**.

Additional Context

Same tooling/config as the zizmor PRs opened against other mitodl repos (e.g. mitodl/ol-keycloak#288, mitodl/ol-keycloakify#177) — this repo already used prek in place of pre-commit, so the hook was added to prek.toml in the equivalent [[repos]]/[[repos.hooks]] form rather than .pre-commit-config.yaml.

Matches the pattern rolled out across other mitodl app repos: a
zizmor-action CI job scoped to workflow-file changes, plus a
zizmor-pre-commit hook in prek.toml so findings surface locally too.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PgiVHUq2Mv2J7bBEAcpe6M
Copilot AI lite review requested due to automatic review settings August 5, 2026 12:35

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds zizmor-based static analysis for GitHub Actions workflows, enforcing consistent linting both in CI (via a dedicated workflow) and locally (via prek) to catch higher-severity workflow issues early.

Changes:

  • Adds a new GitHub Actions workflow that runs zizmorcore/zizmor-action against .github/workflows/ on pushes/PRs touching workflow files.
  • Adds a new zizmor hook to prek.toml using zizmorcore/zizmor-pre-commit with severity/confidence thresholds aligned to CI.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
prek.toml Adds a zizmor prek hook to run GitHub Actions static analysis locally with configured thresholds.
.github/workflows/actions-static-analysis.yml Introduces a CI workflow to run zizmor against .github/workflows/** on relevant pushes/PRs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/workflows/actions-static-analysis.yml Outdated
Matches the sibling checkout step's with: indentation for consistency.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PgiVHUq2Mv2J7bBEAcpe6M
@blarghmatey
blarghmatey merged commit e44b74f into main Aug 5, 2026
6 checks passed
@blarghmatey
blarghmatey deleted the worktree-add-zizmor branch August 5, 2026 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants