srctrekpre-release

A debugger session for code you haven't run.

trek takes a change — a git range or pull requests, across one or more repos — and follows one example scenario from its trigger to its outcome in execution order, moving your editor to each step.

Coming soon Install with one command, on macOS and Linux.

trek's home screen in a terminal: the change's trek is ready, with 19 steps and one step flagged likely wrong, listed with two more treks.
The home screen in a terminal, with sample data.

The problem

Code you didn't write, arriving as a list of files.

  • A change arrives as a flat list of files across one or more repos. Rebuilding the flow from that list — what triggers it, what runs next, where it ends — is the hard part.
  • The usual way to learn a flow is to run it and debug it. For a multi-repo feature that means getting every project, its services, and its data working locally first.

How it works

Three steps. Nothing to run.

  1. Pick a change

    A git range or pull requests, across one or more repos — or work not yet committed.

    trek main...HEAD ../gateway
  2. Your agent builds the trek

    Register trek mcp with your agent. It reads the change at its exact revisions and follows one example scenario from trigger to outcome.

    “Build a trek of this branch.”
  3. Step through it

    In Neovim or VS Code: next and previous in execution order, step over, into, and out, with the narration and call stack for each stop.

    :Trek pay

What you get

Follow the flow, not the file list.

  • Whole flow, change highlighted

    Unchanged code on the path is included and collapsed by default; changed code is where attention goes.

  • Across repos

    One trek crosses repos and async boundaries — HTTP calls, queues, events — and each step names its repo.

  • Checkable

    Every link from one step to the next cites the line that causes it. Predicted values are labeled as predicted; guessed links and risky spots are flagged.

  • Any agent

    Your agent builds treks through trek mcp, a standard MCP server.

What it is not

It shows the flow. The conclusions are yours.

  • Not a summary or a review bot. You step through; nothing is concluded for you.
  • Not a real debugger. Values and paths are predicted from reading code, not observed.
  • Not tied to an editor, an agent, or a code host.
  • Not a tool for review comments or approvals.