The Graphite CLI is a tool to help you break up large engineering tasks into a series of small, incremental code changes directly from the command line. The Graphite CLI makes it easy to stay unblocked as an author, develop faster, and provide more helpful comments as a reviewer.
The Graphite CLI is fully compatible with
git—just install it on an existing repository and begin using our suite of
We recommend installing via Homebrew for smoothest sailing, even on Linux!
brew install withgraphite/tap/graphitegt --version
npm install -g @withgraphite/graphite-cli@stablegt --version
We develop Graphite with Node.js v18, but Graphite should run with no major issues on any current version of Node. If you run into any issues that seem Node-related, try using v18 as a first workaround! If that doesn't work, we recommend the
brew installation, which ships standalone binaries for both MacOS and Linux.
As of v1.0.0, Graphite requires a minimum
git --version of 2.38.0.
If you are running an Ubuntu version whose
apt-get won't update Git to a high enough version for Graphite, you can source the latest version from the
git-core PPA repository.
apt install git
Currently, the best way to install Graphite on Windows is via
npm. If you do not use Node in your day-to-day work, there are a variety of ways to get it set up on your system, listed in the NPM documentation.
Alternatively, you can use either
npm on WSL (Windows Subsystem for Linux).
We are always working towards better native Windows support, although occasionally it falls behind *nix systems in priority. If you run into any issues, especially if they are blocking your workflow, please reach out in our community Slack.
To use Graphite to create or update pull requests in GitHub for the branches in your stack using
gt submit, you must authenticate the CLI with your GitHub account. See Privacy and Security to understand which GitHub permissions Graphite requires.
Sign into https://app.graphite.dev/activate with your GitHub account.
gt auth --token <your_cli_auth_token>command shown (your CLI auth token will be pre-filled for you).
Paste and run it in your terminal.
> gt auth --token <YOUR_AUTH_TOKEN>🔐 Saved auth token to "/Users/pranathiperi/.graphite_user_config"
Once you've authenticated the CLI, you can run
gt submit to create or update pull requests in GitHub for every branch in your stack.
Your privacy and security are our top priorities. Graphite is architected to ask for the minimum set of permissions necessary within the constraints of GitHub's API. Learn more about our GitHub integration.