GitRig
A toolkit that makes day-to-day git work easier — changelists, shelves, branch management and a merge tool, all integrated into the VS Code SCM panel.
Installation
No compilation needed. Download the latest .vsix file from this repository and install it directly:
- Open VS Code
- Go to the Extensions panel (
Ctrl+Shift+X)
- Click the
··· menu → Install from VSIX...
- Select the downloaded
.vsix file
Features
Changelists
Organize your modified files into named groups without staging them. Files added to a changelist are hidden from git's staging area via git update-index --assume-unchanged.
- Create, rename, and delete changelists
- Add files via right-click in the SCM Changes panel
- Remove files or stage them directly from the Changelists panel
- Stage all files in a changelist at once
- Multi-root workspace support
Shelves
Save your current changes to a named shelf and restore them later. Shelved files are automatically reverted from the working tree.
- Create a shelf from selected modified files
- Add individual files to an existing shelf via right-click
- Apply a full shelf or a single file from it
- Delete shelves you no longer need
Right-click any modified file in the SCM Changes panel to access both features:

Branch Management
A full branch management panel in the SCM sidebar with support for local and remote branches.
- Checkout, rename and delete branches
- Create a new branch from any existing one
- Merge a branch into the current one (with auto-stash if working tree is dirty)
- Rebase current branch onto another (with
--autostash)
- Checkout and rebase onto current
- Pull current branch or fast-forward update a local branch from its remote

A 3-panel merge editor that shows the local version, the result (editable), and the incoming version side by side with synchronized scrolling.
- Accept the left or right side per hunk
- Edit the result column manually
- Abort the merge at any time
- After resolving all conflicts and saving, automatically runs
git add and git commit to finalize the merge
When a merge conflict is detected, GitRig shows a notification with a shortcut to open the tool:

The merge tool can also be opened from the Command Palette:


AI Integration (MCP Server)
GitRig includes a built-in MCP (Model Context Protocol) server that allows AI coding assistants like Claude Code to query your changelists and shelves.
How it works
When GitRig activates in a project, it automatically adds its MCP server entry to the .mcp.json file in the project root (gitignored). If the file already exists with other MCP servers configured, GitRig merges its entry without affecting the others. If the GitRig entry is already present and up to date, the file is left untouched. Claude Code reads this file and discovers the GitRig MCP server — no manual configuration needed.
| Tool |
Description |
gitrig_list_changelists |
List all changelists and their files |
gitrig_get_changelist_files |
Get files for a specific changelist |
gitrig_list_shelves |
List all shelves with metadata |
gitrig_get_shelf |
Get shelf details including patch content |
gitrig_get_excluded_files |
Get all files across all changelists (useful for excluding from commits) |
Example usage with Claude Code
"Commit all my changes but don't include the files in the DO NOT COMMIT changelist"
Claude Code will automatically call gitrig_get_excluded_files, identify the files to skip, and stage only the remaining files before committing.
"What files are in my shelves?"
Claude Code will call gitrig_list_shelves and show you the contents.
Manual setup (if auto-discovery doesn't work)
If the .mcp.json wasn't generated automatically, create it in the project root:
{
"mcpServers": {
"gitrig": {
"command": "node",
"args": ["<path-to-extension>/out/mcp/server.js"],
"env": {
"GITRIG_WORKSPACE": "<path-to-your-project>"
}
}
}
}
Replace <path-to-extension> with the GitRig extension path (e.g. ~/.vscode/extensions/MarcelloCosta.gitrig-0.2.2).
Requirements
- VS Code 1.75+
- A git repository in the workspace