gavelcode/gavel

๐Ÿ’ป Developer Tools๐ŸŸข Verified Active
0 Views
0 Installs

๐ŸŽ๏ธ ๐Ÿ  - Code-quality gate for Bazel monorepos: runs lint, coverage and architecture checks off the build graph and returns a pass/fail verdict an agent can request before finishing a change.

Quick Install

One-Click IDE Configuration
claude_desktop_config.json
{
  "mcpServers": {
    "gavelcode-gavel": {
      "command": "npx",
      "args": [
        "-y",
        "gavelcode-gavel"
      ]
    }
  }
}
Or

Using an AI coding agent (Claude Code, Cursor, etc.)? Copy a ready-made prompt that tells it to fetch the setup instructions and install this server for you.

Documentation Overview

Gavel

CI codecov License Bazel

Bazel builds your monorepo. Gavel judges it. Order in the codebase!

The quality gate for Bazel monorepos โ€” build-graph-native, local, agent-ready.

Your monorepo builds green. That's not the same as innocent. Gavel gathers the evidence as Bazel aspects, holds every change to the law you set in gavel.yaml, and returns a verdict: the regression you just introduced stands charged, while a decade of existing debt is not on trial. One verdict, handed to your CI, your terminal, and your coding agent alike.

gavel init      # open the case
gavel judge     # hear it

Gavel judging a Bazel monorepo โ€” a new finding is blocked while a decade of existing debt stays baselined


Install

# Homebrew โ€” macOS & Linux
brew install gavelcode/tap/gavel

# or the install script โ€” Linux, CI, Docker
curl -fsSL https://raw.githubusercontent.com/gavelcode/gavel/main/install.sh | sh

Prebuilt binaries for every platform are on the releases page. Gavel needs a Bazel 8.0+ (bzlmod) workspace; verify with gavel --version.

Build from source
bazel build //apps/cli/cmd/gavel
# binary at bazel-bin/apps/cli/cmd/gavel/gavel_/gavel

How it works

Every change gets its day in court.

1. The evidence comes from the build graph

Analyzers โ€” golangci-lint, PMD, CPD, SpotBugs, Error Prone, Ruff, Bandit, ESLint, Clippy โ€” run as Bazel aspects. They see the exact source tree, dependency graph, and toolchains Bazel already resolves; no separate scanner, no second config to drift. SonarQube re-scans the world; Gavel looks only at the targets the graph says changed (--affected), so a run stays fast as the monorepo grows. Every tool, every language, normalized to one format: SARIF.

2. You're only tried for what you changed

gavel.yaml is the quality gate โ€” code, reviewed and versioned with the repo, not clicked into a web UI. It evaluates only what you just added against a committed baseline: new findings, coverage regressions, new architecture violations. Adopt Gavel on ten years of debt and it blocks on today's diff, never on the backlog.

projects:
  - name: payments
    pattern: "//payments/..."
    tooling:
      go: [golangci-lint, archtest]
    quality_gate:
      findings: { max_error: 0 }
      coverage: { min: 80 }
      architecture_violations: { max: 0 }

Every run saves a fingerprint snapshot; the next shows the delta โ€” new, fixed, existing โ€” plus the coverage trend. No server required.

  payments/api/handler.go:42  error  null check missing  golangci-lint:nilerr  NEW

  โš–  VERDICT: FAIL โ€” code_quality
     1 new ยท 8 fixed ยท 31 existing        coverage 73.5% (โ†‘5.0%)        architecture PASS

3. A verdict your coding agent can request

Coding agents write code they can't see the consequences of โ€” a lint regression, a coverage drop, a layering violation land three commits later in CI. gavel mcp starts a Model Context Protocol server that exposes judge, lint_file, findings, coverage, and arch as tools. Point Claude Code, Cursor, or Zed at it and the agent checks its own work against the same Bazel-aware gate as it writes โ€” a quality conscience, inline.

For editors and dashboards, gavel watch re-analyzes on every save and emits a JSONL event stream. Both run fully local โ€” no server, no network.

Gavel vs SonarQube: the case

SonarQubeGavel
Build-graph awarenessNoneBazel aspects understand target dependencies
Monorepo modelOne project, or a branch per projectHierarchical: per-package, per-project, whole repo
Analysis scopeFull scan or file diffBazel-aware: changed files + affected targets
Local workflowServer round-tripFully local, zero network
Coding-agent / editor loopโ€”MCP server + watch event stream
Quality gateWeb-UI configCode (gavel.yaml), versioned with the repo
Progress trackingServer-backedLocal fingerprint snapshots, no infrastructure
FootprintJava server + database + scannerOne static Go binary, runs inside Bazel

SonarQube is a mature platform with fifteen years of rules behind it, and Gavel isn't trying to replace it. Gavel answers a question SonarQube structurally can't: which packages of my Bazel monorepo are healthy, and did this change make one of them worse โ€” where the build graph is the unit of analysis and the inner loop is where quality is actually won.

Already running aspect's rules_lint? Keep it. Gavel reads the SARIF it drops in bazel-bin/ (gavel judge --findings-source=rules_lint) and turns those reports into a gate โ€” baseline delta, coverage, architecture, verdict โ€” the layer rules_lint deliberately leaves to you.

Status

Alpha โ€” v0.1.0. Under active development; APIs and config formats may change. Gavel gates its own repository on every commit โ€” it is its own first user.

Working today:

  • gavel init โ€” scaffold config + Bazel integration
  • gavel judge โ€” analyze, evaluate the gate, show findings and the delta
  • gavel judge --project <name> ยท --quick ยท --summary ยท --affected โ€” scope and shape the run
  • gavel judge --absolute โ€” evaluate all findings (release gates, nightly)
  • gavel judge --json ยท --output-sarif report.sarif โ€” structured output for CI, IDEs, GitHub Code Scanning
  • gavel judge --server URL --token TOKEN โ€” shared team baseline: fetch and submit
  • gavel watch โ€” re-analyze on change, emitting a JSONL event stream
  • gavel mcp โ€” Model Context Protocol server for editor / agent integration
  • gavel validate โ€” check Bazel integration health
  • Baseline mode (default): fingerprint-based new/fixed/existing classification, committed to git for the team
  • Analyzers: golangci-lint, PMD, CPD, SpotBugs, Error Prone, Ruff, Bandit, ESLint, Clippy
  • Server (optional): web dashboard, centralized history, team baselines, API-token auth

Documentation

Contributing

Issues and pull requests are welcome โ€” see CONTRIBUTING.md and our Code of Conduct. Security reports go through SECURITY.md.

License

Apache License 2.0

Related MCP Servers

Moxie-Docs-MCPโ˜… Featured

MCP & Agent Skills for Automated Documentation, and codebase conventions + context

๐Ÿ’ป Developer Tools2 views
3KniGHtcZ/codebeamer-mcp

๐Ÿ“‡ โ˜๏ธ ๐ŸŽ ๐ŸชŸ ๐Ÿง - Codebeamer ALM integration for managing work items, trackers, and projects. Provides 17 tools for reading and writing items, associations, references, comments, and risk management data via Codebeamer REST API v3.

๐Ÿ’ป Developer Tools1 views
21st-dev/Magic-MCP

Create crafted UI components inspired by the best 21st.dev design engineers.

๐Ÿ’ป Developer Tools0 views
a-25/ios-mcp-code-quality-server

๐Ÿ“‡ ๐Ÿ  ๐ŸŽ - iOS code quality analysis and test automation server. Provides comprehensive Xcode test execution, SwiftLint integration, and detailed failure analysis. Operates in both CLI and MCP server modes for direct developer usage and AI assistant integration.

๐Ÿ’ป Developer Tools0 views

Engagement

Views
0
Installs
0
Upvotes
0

Views and upvotes are unique per visitor network (hashed IP). Installs count copy actions.

Status

Health: Active

Recent health check succeeded.

Last checked: 7/29/2026, 10:18:05 AM

Unclaimed listing (imported or pending owner verification). Claim it โ†’
โ˜… Spotlight Slot

Feature Your MCP Server

Get maximum visibility for your server across our directory, search results, and detail pages.

Spotlight Your Server

Own this project?

This directory is pre-filled from public sources. Claim via GitHub README, site badge, or DNS TXT to get the verified badge and attach your website.

Claim this listing

Promote this listing

Optional paid placement. Free listings stay free forever.

Share & Embed

Add our SVG badge (dark/light directory styles) or embeddable widget to your site.