Inspiration

AI agents now write much of the code and the tests that check it. Patches pass CI, yet they copy the same rule into several places, and their tests assert nothing. A green checkmark no longer means the code is safe to change.

What it does

greenline is a CLI that compares two patches, or checks one PR, and shows where green CI lies:

  • Duplicated rules: the same logic copied into N places, with every location.
  • Change simulation: changes the rule in one place and shows the exact input on which the code paths start to disagree.
  • Mutation testing on changed lines: breaks the code on purpose and shows every mutant the tests failed to catch.
  • Empty tests and uncovered changed lines.
  • Risk score from 0 to 100 with an open formula. It is deterministic: the same input always gives the same report hash.
  • Optional AI explanations for each finding (--explain), clearly labeled as unverified. They never change the score.

The output goes to the terminal, JSON, Markdown PR comments and SARIF annotations in GitHub.

How we built it


Challenges we ran into


Accomplishments that we're proud of


What we learned


What's next for greenline

  • JS/TS support through tree-sitter.
  • Accepting findings with a reason, with an AI check of that reason.
  • Learning which mutants developers find useful.
  • A GitHub App for one-click setup.

Built With

  • claude
Share this project:

Updates

Submission history