freeze

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

Updated Apr 12, 2026
One-click install
npx skills add https://github.com/2300031147/clawopencode --skill freeze-2300031147
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: freeze
Source: https://github.com/2300031147/clawopencode/tree/main/skills/freeze
Command: npx skills add https://github.com/2300031147/clawopencode --skill freeze-2300031147

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Restricts edits to a designated directory for the active session.

Core Features & Use Cases

  • Boundary enforcement via a PreToolUse hook that validates the target file_path against the configured freeze boundary.
  • Session persistence by storing the boundary in a state file so it remains active across commands within the session.
  • Safe debugging workflow by isolating changes to a single module and blocking edits outside the boundary during development.

Quick Start

Ask the user which directory to freeze, resolve the path, and save it as the active freeze 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, you can establish a freeze boundary that remains active for the session. A PreToolUse hook validates file paths and blocks any Edit or Write operations attempted outside the designated folder.

How does a PreToolUse hook isolate code changes to a single folder?

A PreToolUse hook isolates code changes by validating the target file_path against a stored boundary before any operation executes. It actively blocks Edit or Write commands that target files outside the designated directory.

Can I keep a directory edit boundary active across multiple bash commands?

Yes, the directory edit boundary remains active across multiple bash commands because it is persisted in a state file. This session control mechanism ensures the freeze restriction stays enforced without requiring reconfiguration for each new command.

What is the best way to prevent accidental file modifications outside a project module?

The best way to prevent accidental file modifications outside a project module is to freeze the target directory. This creates a safe debugging workflow by establishing a hard boundary that blocks all edits to files outside that specific folder.

Does freezing a directory block both reading and writing files outside the boundary?

Freezing a directory does not block reading files outside the boundary; it specifically targets and blocks Edit and Write operations. The PreToolUse hook enforces this restriction solely to prevent modifying file contents outside the designated folder.