AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Branch Sandbox

skill-aquish-lee-agent-handrails-branch-sandbox · by Aquish-Lee

Create a branch, worktree, or scratch clone when a user explicitly requests isolation or a risky or parallel coding task needs a reversible workspace boundary. Use for broad refactors, migrations, autonomous runs, and concurrent work; skip routine micro-tasks and read-only investigation.

No reviews yet
0 installs
4 views
0.0% view→install

Install

$ agentstack add skill-aquish-lee-agent-handrails-branch-sandbox

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-aquish-lee-agent-handrails-branch-sandbox)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
27d ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Branch Sandbox? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Branch Sandbox

Create only the isolation that materially reduces rollback, interference, or working-tree risk. Isolation is a process boundary, not proof that a change is correct or authorized.

Read [the local v2 contract](references/usable-loop-v2.md) when you need record fields, authority rules, Checkpoint triggers, or runtime details.

Decide whether to isolate

Use a worktree or branch for broad refactors, migrations, generated assets, long autonomous work, experiments, concurrent tasks, production-like files, or when the current checkout must remain usable. Prefer:

  • no sandbox for a clear micro-task or read-only investigation;
  • a branch when the checkout is clean and may be occupied by this task;
  • a worktree when another branch/check-out must remain available;
  • a scratch clone only for clean-clone, remote, or dependency isolation.

Do not silently pass control to another handrail. Return the sandbox result and let the caller decide what happens next.

Establish authority and state

Treat the current user request as authoritative when the user controls the task and no permission or designated-source conflict exists. Otherwise mark derived meaning provisional and expose the conflict.

Run the read-only preflight:

git rev-parse --show-toplevel
git status --short
git branch --show-current
git rev-parse HEAD
git worktree list
python /scripts/handrails_state.py inventory \
  --compact --repository . --base HEAD > 

Resolve ` from this installed SKILL.md, not from the project working directory. Inside this source repository, runtime/handrails_state.py` is the canonical equivalent.

The runtime inventories staged, unstaged, committed-since-base, and untracked state. Add ignored artifacts only with explicit --declare-ignored arguments. Never infer or scan ignored caches, secrets, or local files. Keep the machine inventory private and query only its digest, conflicts, counts, and path/layer summary for the Work Boundary decision. The private path must be outside participating worktrees or ignored and undeclared. Do not declare .scratch merely because Handrails logs live there; declarations are only for ignored content the task explicitly makes a candidate.

If a Review Boundary Seed exists, consume it as a hypothesis. Record actual task-start state and the delta from the seed; do not convert expected paths into an allowlist. Without a seed, report No seed supplied.

For a dirty checkout:

  • keep it untouched by creating a worktree from a clean base when it is unrelated;
  • include it only when the user says it belongs to this task;
  • stop when ownership is ambiguous;
  • stash only after explicit authorization.

Create the boundary

Use a repository-conforming branch name. Typical commands are:

git switch -c /
git worktree add -b /  
git clone  

After creation, recapture branch, HEAD, status, and participating worktrees. Return a compact Work Boundary containing:

  • Task ID and Outcome Revision;
  • workspace identity and actual task-start state;
  • Review Boundary Seed delta, if any;
  • participating workspaces and authorization guardrails;
  • explicitly declared ignored artifacts;
  • base/recovery identity, sandbox location, rollback path, and stale conditions.

Paths and expected changes remain hypotheses. The later claim/review boundary must inventory all current candidates again.

Safety and cleanup

Never auto-run stash, reset, rebase, overwrite, force branch deletion, or remove a worktree that contains results. Ask for explicit authorization for each such operation. By default, report the cleanup command and its preconditions without executing it.

Before proposing worktree removal, show status, branch, HEAD, and whether the results are integrated or recoverable. Never use isolation as a reason to hide or delete pre-existing work.

Direct result

Keep the ordinary result compact: chosen isolation, exact location/base, captured dirty-state limitation, rollback/cleanup command, and the necessary next step. Expand a Checkpoint only for a trigger listed in the local contract.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.