using-jj-workspaces

Creates and manages isolated Jujutsu workspaces for parallel feature development.

3|Updated Sep 18, 2025
One-click install
npx skills add https://github.com/KingMichaelPark/dotfiles --skill using-jj-workspaces-kingmichaelpark
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: using-jj-workspaces
Source: https://github.com/KingMichaelPark/dotfiles/tree/main/ai/.agents/skills/using-jj-workspaces
Command: npx skills add https://github.com/KingMichaelPark/dotfiles --skill using-jj-workspaces-kingmichaelpark

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? When working in a Jujutsu (jj) repository, developers sometimes need a fully isolated filesystem workspace for parallel agent execution or sandboxed feature work, but misusing workspaces (or falling back to raw git commands) leads to nested-repo errors and broken states. This Skill provides a disciplined workflow for deciding when a workspace is actually needed and setting it up correctly. ## Core Features & Use Cases - Need Assessment First: Defaults to plain jj flows (jj new, jj edit, mutable commits) and only creates a workspace when isolation is explicitly required. - Correct Workspace Setup: Creates a base commit, adds the workspace as a sibling directory (never nested), and auto-detects project setup for Node, Rust, Python, and Go. - Baseline Verification & Cleanup: Runs project tests to confirm a clean starting state and provides commands to forget and remove workspaces when done. - Use Case: An AI agent needs to execute an implementation plan in isolation while you continue other work; the Skill creates ../feature-x via jj workspace add, installs dependencies, and verifies tests pass before starting. ## Quick Start Ask the assistant to set up an isolated Jujutsu workspace for your new feature work in the current jj repository.

Frequently Asked Questions about using-jj-workspaces

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a workspace in a Jujutsu jj repository?

Run `jj new` to create a base commit, then `jj workspace add ../feature-name` to add the workspace as a sibling directory of the main repo. Change into that directory and run your project's setup commands before starting work.

When should I use jj workspaces versus plain jj commits?

Plain jj flows using `jj new`, `jj edit`, and mutable commits handle most concurrent development and are preferred. Only create a workspace when you explicitly need filesystem isolation, parallel agent execution, or a sandboxed environment.

Can I use git worktree commands in a jj repository?

No. When a `.jj/` directory exists, you must use `jj workspace` commands instead of `git worktree`. Mixing raw git commands with jj workspaces can corrupt repository state.

Why does my jj workspace fail when created inside the main repo?

Jujutsu workspaces must be siblings of the main repository, not nested inside it, to avoid invalid nested repository states. Always add workspaces to a path like `../workspace-name`.

How do I remove a jj workspace when finished?

From the main repository, run `jj workspace forget <workspace-name>` to unregister it, then delete the directory with `rm -r ../<workspace-name>`. This cleanly removes both the jj tracking and the files.