Skip to content

feat: CLI tool for CI/CD integration — run reviews without VS Code (post-MVP roadmap) #47

Description

@charannyk06

Priority: P3 — Low (Roadmap)

Problem

ChainReview is currently only available as a VS Code extension. This prevents:

  • Running reviews in GitHub Actions / GitLab CI pipelines
  • Pre-merge review gates without VS Code
  • Headless server environments
  • Scripted review automation

Proposed Solution

Create a chainreview CLI tool that wraps the same MCP server:

# Install
npm install -g chainreview

# Run a review
chainreview review ./src --output json > findings.json

# Run a review and fail CI if high severity findings exist
chainreview review ./src --fail-on high

# Run with specific agents only
chainreview review ./src --agents security,bugs

# Output formats
chainreview review ./src --format markdown > REVIEW.md
chainreview review ./src --format sarif > results.sarif  # GitHub Code Scanning compatible

Architecture

The CLI would:

  1. Start the MCP server as a child process (or in-process)
  2. Call the runReview tool programmatically
  3. Stream findings to stdout in the requested format
  4. Exit with code 0 (pass) or 1 (fail based on severity threshold)

GitHub Actions Integration

- name: ChainReview
  uses: charannyk06/chainreview-action@v1
  with:
    anthropic-api-key: ${{ secrets.ANTHROPIC_API_KEY }}
    fail-on: high
    agents: security,bugs

SARIF Output

SARIF format integrates with GitHub Code Scanning, GitLab SAST, and other security dashboards.

Acceptance Criteria (Future)

  • chainreview CLI installable via npm
  • review command works on a local directory
  • JSON, Markdown, SARIF output formats
  • --fail-on threshold support
  • GitHub Actions action created
  • Documented in README

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions