gstack 1.91.47.0: /careful and /guard now check PowerShell, and /freeze covers notebooks

3 days ago

gstack 1.91.47.0 (2026-10-08) for Claude Code users: /careful and /guard now catch destructive PowerShell and cmd commands on Windows, encoded or dynamic PowerShell asks first, and /freeze now blocks notebook edits outside the folder you froze. https://github.com/garrytan/gstack/blob/main/CHANGELOG.md#191470---2026-10-08

Ask

Ask about this presentation

Answers are generated from this presentation.

Chapters

  1. 0:00PowerShell on Windows
  2. 0:13Shells launched from Bash
  3. 0:27Notebook edits
  4. 0:40Limits
Show transcript

PowerShell on Windows

gstack logo

gstack 1.91.47.0: /careful and /guard now check PowerShell commands

PS> Remove-Item -Recurse -Force C:\projbefore: no prompt
PS> Remove-Item -Recurse -Force C:\projnow: asks first
WindowsFrom BashNotebooksLimits
garrytan/gstack · CHANGELOG.md 1.91.47.0

On Windows, Claude Code runs commands through its PowerShell tool. /careful and /guard never saw those, so a forced recursive delete ran with no prompt. Now it asks first, naming the pattern it matched.

Shells launched from Bash

A delete inside pwsh or cmd, launched from Bash, now asks too

pwsh -c "Remove-Item -r -fo x"asks
cmd /c "rd /s /q x"asks
-EncodedCommand · iex · & $cmdasks: can’t inspect
git branch -d · Remove-Item x.txtstill allowed
WindowsFrom BashNotebooksLimits
garrytan/gstack · CHANGELOG.md 1.91.47.0

The check also covers a Bash command that launches PowerShell or the Windows command prompt. Encoded or dynamic PowerShell asks too, because gstack can't inspect it. Deleting one file still runs without a prompt.

Notebook edits

/freeze now blocks notebook edits outside the folder you froze

NotebookEdit /etc/x.ipynbbefore: allowed
NotebookEdit /etc/x.ipynbnow: denied
The denial names the tool, the notebook path, the boundary and /unfreeze
WindowsFrom BashNotebooksLimits
garrytan/gstack · CHANGELOG.md 1.91.47.0

On every platform, notebook edits slipped past /freeze, /guard and /investigate. A notebook edit outside the frozen folder is now denied. The message names the tool, the path and how to unfreeze.

Limits

PowerShell checks are best-effort, so add deny rules for a hard stop

runtime commandsPowerShell can build a command that string matching can’t see
hard stopClaude Code permission deny rules parse PowerShell and match aliases
WindowsThe hooks run through bash, so they still need Git Bash
CHANGELOG.md · 1.91.47.0What this means for you
WindowsFrom BashNotebooksLimits
garrytan/gstack · CHANGELOG.md 1.91.47.0

The PowerShell check is best-effort: a command built at runtime can slip past it. For a hard stop, add Claude Code permission deny rules. On Windows, the hooks still need Git Bash, which gstack already requires.