sheriff.

Introduction

Sheriff brings open-source test workflows to Claude Code and Codex. Learn how to find test gaps, write tests, and keep JavaScript and TypeScript coverage in sync.

Sheriff is a testing orchestration layer for Claude Code and Codex. It finds test gaps, plans the work, and writes and runs tests for your JavaScript or TypeScript project.

How Sheriff works

Start with your project, choose a test scope, and let Sheriff work through the gaps. The workflow follows four steps:

  • Discover — map source files, existing tests, and missing coverage.
  • Plan — organize the work into phases you can review.
  • Test — write and run tests for the agreed scope.
  • Report — record results, failures, and work that still needs attention.

After changing your code, sync your tests to check the behavior affected by those changes.

Your AI tool, your workflow

Sheriff runs inside Claude Code or Codex. The commands use different prefixes, but both integrations share the same project state in .sheriff/.

Claude CodeCodex
/sheriff:run$sheriff-run
/sheriff:sync$sheriff-sync
/sheriff:status$sheriff-status

Claude Code gets commands, role instructions, and hooks. Codex gets a main skill and six action skills sharing one runtime, without hooks or a statusline.

Run only one Sheriff session per project at a time, even when both integrations are installed.

Before you start

  • Node.js 18 or newer.
  • Your project’s npm, pnpm, Yarn, or Bun package manager available in the terminal.
  • Claude Code or Codex installed and ready to use.
  • A JavaScript or TypeScript project in a Git repository.

A test runner is optional at the start. Sheriff detects an existing runner or helps configure one within your authorization. Browser and service tests require their own working environment.

Next steps

Install Sheriff, then run your first workflow.

Sheriff is MIT licensed. Access to Claude Code or Codex and model usage are separate from Sheriff itself.