freeze

Restrict file edits to a specified directory using a PreToolUse hook.

Updated Jun 18, 2026
One-click install
npx skills add https://github.com/abhishekmmgn/didactic-invention --skill freeze-abhishekmmgn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: freeze
Source: https://github.com/abhishekmmgn/didactic-invention/tree/main/.agents/skills/gstack/freeze
Command: npx skills add https://github.com/abhishekmmgn/didactic-invention --skill freeze-abhishekmmgn

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Restrict file edits to a specific directory for the current session, preventing accidental edits outside the designated boundary and helping teams avoid unintended changes.

Core Features & Use Cases

  • Enforces a runtime boundary that blocks Edit and Write operations outside the configured directory.
  • Interactive setup using AskUserQuestion to capture the target directory from the user.
  • Persistent boundary stored in a state file so the restriction remains active during the session.
  • Transparent and reversible: users are informed when edits are denied and can adjust or remove the boundary.

Quick Start

Provide the directory path to restrict edits to and run the freeze command to enable the boundary.

Frequently Asked Questions about freeze

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

FAQPage Schema
How do I restrict file edits to a specific directory during a bash session?

To restrict file edits to a specific directory during a bash session, you can use a boundary-check script that blocks Edit and Write operations outside the designated path, storing the boundary in a state file to prevent accidental modifications.

What is directory-boundary enforcement and how does it prevent accidental file modifications?

Directory-boundary enforcement is a mechanism that intercepts file operations via a PreToolUse hook, checking requested paths against a stored boundary to block any edits outside the locked directory and prevent accidental modifications.

Can I lock changes to a single module while debugging without affecting other files?

Yes, you can lock changes to a single module while debugging by setting a runtime boundary that specifically affects Edit and Write operations, ensuring your session does not accidentally modify files outside the designated directory.

How do I set up or remove a directory edit restriction for my current session?

To set up a directory edit restriction, you run a command that interactively captures your target directory and stores it in a state file. The boundary is reversible, allowing you to adjust or remove the restriction at any time.

Does the edit restriction boundary persist across different bash session-management tools?

The edit restriction boundary persists during the current session by storing the configuration in a state file, ensuring the directory lock remains active and transparently blocks edits until you explicitly remove or adjust it.