gstack-freeze
Skill2 starsChanged 23 days agoApache-2.0View on GitHub
Restrict file edits to a specific directory for the session. (gstack)
2 other projects use a version of this, 2 of them edited.
Adopted by
Most recently taken up by
- robertkarl/rkstackedited, first seen Oct 20, 2026
- sagnikmitra/skillsedited, first seen Jun 8, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 2
- sagnikmitra/skills★ 162% same
- robertkarl/rkstack★ 071% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository40 other files it gives its agents.
- caveman-commitSkill
- caveman-reviewSkill
- cavemanSkill
- gstack-autoplanSkill
- gstack-carefulSkill
- gstack-csoSkill
- gstack-design-reviewSkill
- gstack-guardSkill
- gstack-investigateSkill
- gstack-office-hoursSkill
- gstack-plan-ceo-reviewSkill
- gstack-plan-design-reviewSkill
- gstack-plan-devex-reviewSkill
- gstack-plan-eng-reviewSkill
- gstack-qaSkill
- gstack-retroSkill
- gstack-reviewSkill
- gstack-shipSkill
- ponytail-auditSkill
- ponytail-debtSkill
- ponytail-reviewSkill
- ponytailSkill
- brainstormingSkill
- dispatching-parallel-agentsSkill
- executing-plansSkill
- finishing-a-development-branchSkill
- receiving-code-reviewSkill
- requesting-code-reviewSkill
- subagent-driven-developmentSkill
- systematic-debuggingSkill
- test-driven-developmentSkill
- using-git-worktreesSkill
- using-superpowersSkill
- verification-before-completionSkill
- writing-plansSkill
- writing-skillsSkill
- tandem-db-safetySkill
- tandem-harnessSkill
- tandem-reviewSkill
- tandem-worktree-etiquetteSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
Write outside the allowed path.
- Distinctive: line 17
Use when asked to "freeze", "restrict edits", "only edit this folder", or "lock down edits".
- Distinctive: line 28
Ask the user which directory to restrict edits to.
- Distinctive: line 41
Ensure trailing slash and save to the freeze state file:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Tandem vendoring note. Vendored from gstack (MIT, (c) Garry Tan, https://github.com/garrytan/gstack @ a3259400). The upstream Claude-Code-specific boilerplate (telemetry, session tracking, update checks, plan-mode hooks, learnings/brain sync) was removed; the workflow itself is unchanged. Paths below are relative to this skill's directory; sibling skills live at
../<id>/(ids are prefixedgstack-).$GSTACK_ROOTis an optional upstream gstack install (default~/.claude/skills/gstack) needed only for optional helpers such as thebrowsebinary; skip any step that needs it when it is absent. "Ask the user" means a plain chat question when no structured question tool exists.
When to invoke this skill
Blocks Edit and Write outside the allowed path. Use when debugging to prevent accidentally "fixing" unrelated code, or when you want to scope changes to one module. Use when asked to "freeze", "restrict edits", "only edit this folder", or "lock down edits".
/freeze — Restrict Edits to a Directory
Lock file edits to a specific directory. Any Edit or Write operation targeting a file outside the allowed path will be blocked (not just warned).
Setup
Ask the user which directory to restrict edits to. Use ask-the-user:
- Question: "Which directory should I restrict edits to? Files outside this path will be blocked from editing."
- Text input (not multiple choice) — the user types a path.
Once the user provides a directory path:
- Resolve it to an absolute path:
FREEZE_DIR=$(cd "<user-provided-path>" 2>/dev/null && pwd)
echo "$FREEZE_DIR"- Ensure trailing slash and save to the freeze state file:
FREEZE_DIR="${FREEZE_DIR%/}/"
eval "$($GSTACK_ROOT/bin/gstack-paths)"
STATE_DIR="$GSTACK_STATE_ROOT"
mkdir -p "$STATE_DIR"
echo "$FREEZE_DIR" > "$STATE_DIR/freeze-dir.txt"
echo "Freeze boundary set: $FREEZE_DIR"Tell the user: "Edits are now restricted to <path>/. Any Edit or Write
outside this directory will be blocked. To change the boundary, run /freeze
again. To remove it, run /unfreeze or end the session."
How it works
The hook reads file_path from the Edit/Write tool input JSON, then checks
whether the path starts with the freeze directory. If not, it returns
permissionDecision: "deny" to block the operation.
The freeze boundary persists for the session via the state file. The hook script reads it on every Edit/Write invocation.
Notes
- The trailing
/on the freeze directory prevents/srcfrom matching/src-old - Freeze applies to Edit and Write tools only — Read, Bash, Glob, Grep are unaffected
- This prevents accidental edits, not a security boundary — Bash commands like
sedcan still modify files outside the boundary - To deactivate, run
/unfreezeor end the conversation
Enforcement outside Claude Code (Tandem note)
Upstream enforces this skill with a Claude Code PreToolUse hook. Other agents have no such hook, so you must self-enforce: before every shell command or file edit, run the matching check script from this skill's bin/ directory (bin/check-careful.sh / bin/check-freeze.sh; they read the tool-input JSON on stdin) or apply the same rules by hand, and stop to ask the user whenever a rule trips. Tandem's own sandbox and permission cards remain the hard boundary.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

