# jujutsu

> Lets coding agents work in Jujutsu (jj) repositories through the jujutsu-mcp tools, without git commands or a shell.

jujutsu is a free AI agent skill on Agensi by Leonardo Lucas de Castro Filho, in DevOps & Cloud. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [Leonardo Lucas de Castro Filho](https://www.agensi.io/creators/luka-kuuhaku)
- Category: [DevOps & Cloud](https://www.agensi.io/skills/devops-cloud)
- Uses: 2
- Version: 1.0
- Last updated: 2026-10-08
- Security: scan passed (2026-10-08); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/jujutsu
- Tags: devops, ai-agents, automation, jujutsu, vcs, git, jj, version-control

## About this skill

Coding agents are trained on git. Put one in a Jujutsu (jj) repository and it reaches for `git add`, opens an editor that never closes, or pushes the wrong commit. This skill teaches the agent to work through the [jujutsu-mcp](https://github.com/LLawli/jujutsu-mcp) server instead: one typed tool per jj operation, and nothing that can hang waiting for input.

### What it does
- **Detects jj repositories** (`.jj`) and keeps git read-only, with a table that maps each git reflex (add, commit, stash, checkout, pull, push) to the right jj tool.
- **Commits and reshapes history** by change id: separate commits, split, squash, rebase, edit an older commit, keeping stray files (logs, build output) out of what gets committed.
- **Syncs with the remote**: fetches, rebases onto trunk, resolves conflicts the jj way and returns the history to a straight line. Semantic conflicts (both sides changed the same value) go to you.
- **Prepares pushes safely**: points the bookmark at the real tip of the work, runs a dry run first and tells you how many commits will be signed, one security-key touch each.
- **Undoes mistakes** through jj's operation log.

### Loads only what the task needs
`SKILL.md` is a short router. Each action has its own reference file (commit, reshape, sync, recover, setup, tools), and the agent reads one only when it performs that action.

### Requirements
- jj 0.45.1 or newer.
- The jujutsu-mcp server, free and open source (MIT or Apache-2.0): `brew install LLawli/tap/jujutsu-mcp` or `cargo install jujutsu-mcp`, then `jujutsu-mcp setup` to register it in Claude Code, Codex and Antigravity.

If the server is missing, the skill walks the agent through installing it, asking you first.

### Tested
Run end to end by an agent on a scenario with a stray file, two separate commits, a conflict with origin and push preparation. It loaded 3 of the 6 references, kept the stray file out, resolved the conflict, left a straight history and stopped at the dry run. That session is the demo on this page.

## Requires

- Jujutsu MCP

## Known limitations

Requires the jujutsu-mcp server to be installed and registered. jj commands that open an editor, pager or merge tool are never used; conflicts are resolved by editing files. jj does not push git tags, so tags are created and pushed with git.

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the jujutsu skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### Why does my coding agent need this skill if it already knows Git?

Most AI agents are hardcoded to use Git commands, which can corrupt Jujutsu (jj) repositories or hang indefinitely. This skill acts as a translation layer, teaching agents to use the `jujutsu-mcp` server to handle commits, rebasing, and conflict resolution safely.

### Which AI agents and software versions are supported?

The skill supports any AI agent that can interface with Model Context Protocol (MCP) servers, including Claude Code, Codex, and Antigravity. It requires `jj` version 0.45.1 or newer and the open-source `jujutsu-mcp` server installed on your machine.

### What specific files or documentation am I getting with this purchase?

The skill includes a 'SKILL.md' router and six specialized reference modules (commit, reshape, sync, recover, setup, and tools). These modules guide the agent through specific JJ workflows while minimizing token usage by only loading what is necessary for the current task.

### Can this skill handle advanced Jujutsu features like change ID reshaping and history editing?

Yes, the skill is designed to handle complex JJ workflows including multi-commit reshaping, rebasing onto trunk, and jj-style conflict resolution. It provides the agent with a mapping table to translate standard Git reflexes into the correct JJ operations like `describe`, `rebase`, and `squash`.

### How does the skill prevent the agent from making destructive changes to my repository?

Safety is built-in: the skill enforces dry runs before any remote push and alerts you to the number of commits requiring signature. It also uses JJ's operation log to allow the agent to undo mistakes, and it prevents the agent from accidentally committing build logs or stray files.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
