Documentation menu

graph_sitter.cli

The Graph-sitter CLI helps you:

  • Parse a local repository into graph summary data
  • Inspect files and trace call relationships from the command line
  • Diagnose parse time, memory use, and graph size for a local repository
  • Initialize Graph-sitter in your repository
  • Create and run codemods
  • Run one-shot transformations and focused renames

For installation instructions, see our Getting Started guide.

Getting Started

  1. Parse a repository without project initialization:
graph-sitter parse . --format json

Run the same command from a published package with uvx:

uvx --python 3.13 graph-sitter parse . --format json

See uvx workflows for branch-built wheel validation and release gate details.

  1. Diagnose a repository with timing and memory stats:
uvx --python 3.13 graph-sitter diagnose .
  1. Initialize Graph-sitter in your repository:
graph-sitter init
  1. Create your first codemod:
graph-sitter create my-codemod .

Available Commands