Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

Graphite CLI

$ gt Official Med Risk
Graphite · Code & DevOps · Proprietary · macos / linux

Official CLI from Graphite for creating, restacking, syncing, and submitting dependent GitHub pull request stacks. Supports --no-interactive (--quiet) for headless execution, though it lacks JSON output and performs remote Git/PR mutations.

FCRS-1.0 Score
78 /100
Good
Medium Confidence
Zero-Friction Install
brew install withgraphite/tap/graphite
CLI vs MCP Decision CLI Preferred vs MCP

Stacked branch restacking and PR submission run directly against local git state via gt; faster and more reliable than remote MCP calls.

Agent-Readiness Checklist

— JSON Output
— Field Filtering
✓ Non-Interactive
— Dry-Run
— Read-Only Mode
— NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 17 / 25

Provides --no-interactive and explicit -m/--no-edit flags, but omits --json output and defaults to interactive prompts when flags are missing.

  • Supports --no-interactive and --quiet across commands
  • No --json output on gt log or gt state
Trust & Safety 17 / 25

Writes local git branches/rebases and pushes/creates GitHub PRs via gt submit; lacks a global --dry-run mode and authenticates via long-lived user_config token.

  • gt submit --stack pushes multiple branches and PRs at once
  • No global --dry-run flag
Setup & Portability 12 / 15

Available via Homebrew tap and npm (@withgraphite/graphite-cli), requiring Node.js or Homebrew formula on macOS/Linux (Windows requires WSL).

  • Requires Node.js (npm) or macOS/Linux Homebrew tap
Utility & Efficiency 14 / 15

Dramatically simplifies stacked-PR rebasing, tracking parent branches, and batch PR updates.

  • Automates multi-branch restacking and dependent PR base updates
Maintenance & Lineage 10 / 10

Official first-party CLI actively maintained by Graphite.

  • Official Graphite product CLI
Docs & Verifiability 8 / 10

Good official CLI reference at graphite.dev/docs/graphite-cli and --help output.

  • Official command docs at graphite.dev

Security, Auth & Guardrails

Auth Modes
OAuth Browser Config File
Credential Storage

Stores Graphite/GitHub OAuth token in ~/.config/graphite/user_config (set via gt auth --token).

Side Effects
Read-Only Local Write Remote Write Destructive
Cost & Quotas

Free CLI for individual/open-source use; Graphite team plans require paid seats.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# Graphite CLI (gt) Agent Rules
- Always pass `--no-interactive` (and `--no-edit` on `gt submit`) so `gt` never waits for terminal input.
- Never run `gt submit` or `gt merge` without explicit user confirmation, as both push branches and mutate GitHub PRs.
- Inspect the stack first with `gt log short --no-interactive`.

Agent-Ready Command Recipes

Safe Read-Only Queries

Inspect current branch stack hierarchy
gt log short --no-interactive

Prints a compact tree of stacked local branches without entering interactive navigation.

Controlled Writes & Previews

Create a stacked commit/branch non-interactively
gt create -a -m "feat: step 1" --no-interactive

Stages tracked changes and creates a stacked branch on top of the current branch without launching prompts or an editor.

Strengths for Agents

  • + --no-interactive prevents terminal hangs on gt create, gt sync, and gt submit.
  • + Handles dependent branch restacking and GitHub PR base updates cleanly in stacked workflows.

Caveats & Pitfalls

  • ! No --json output for stack state inspection.
  • ! Proprietary CLI tied to Graphite's GitHub PR workflow; Windows is only supported via WSL.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI