Skip to content

Repository files navigation

RepoWright

RepoWright is a provider-neutral coding agent for local Git repositories. It can inspect a repository, apply hash-guarded patches, run validation, persist its event history, and resume interrupted sessions.

RepoWright V2 runs project commands with your local user permissions. Its path and approval policies reduce accidental impact, but they are not a security sandbox.

Requirements

  • Node.js 22 or newer
  • Git
  • macOS or Linux

Install for development

pnpm install
pnpm build
pnpm link --global

Configure

repowright config init
export OPENAI_API_KEY="..."
repowright config validate
repowright doctor

Configuration is loaded in this order:

  1. CLI flags
  2. REPOWRIGHT_PROFILE and REPOWRIGHT_APPROVAL
  3. .repowright/config.toml in the repository
  4. ~/.config/repowright/config.toml

Credentials are referenced by environment-variable name and are never written to configuration files.

Use

# Open the interactive terminal UI
repowright

# Open the UI and immediately start this task
repowright "Fix the failing order idempotency test"
repowright --profile primary --approval cautious "Review this repository"

# Non-interactive mode for scripts and CI
repowright --print "Explain the current Git diff"

repowright sessions list
repowright sessions show <id>
repowright sessions resume <id> "Continue after the dependency issue is fixed"

Interactive commands and keys:

  • /help: show commands.
  • /clear: clear the conversation view.
  • /exit or /quit: leave the UI.
  • Enter: submit a prompt.
  • Ctrl+C: cancel the active operation; when idle, exit.
  • y / n: answer a tool approval request.

When stdin is not a TTY, RepoWright automatically uses print mode and requires a prompt.

Approval modes:

  • cautious: confirm writes and commands.
  • balanced: allow scoped edits and recognized validation; confirm risky commands.
  • autonomous: allow more local commands, while still gating external or destructive operations.

Providers

  • OpenAI Responses API
  • Anthropic Messages API
  • Google GenAI API
  • OpenAI-compatible Chat Completions endpoints with tool-calling support

RepoWright intentionally does not emulate tool calling by parsing model-generated JSON. An endpoint must support structured function/tool calls.

Development

pnpm typecheck
pnpm lint
pnpm test
pnpm test:integration
pnpm pack

Data

Sessions are stored as append-only JSONL under:

~/.local/share/repowright/sessions/<session-id>/

Telemetry is disabled. Session records remain local unless you share them.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages