{ "permissions": { "allow": [ "Bash(tclsh90 src/tests/runtests.tcl *)", "Bash(tclsh src/tests/runtests.tcl *)", "Bash(/c/Users/sleek/AppData/Local/Apps/Tcl903/bin/tclsh90 src/tests/runtests.tcl *)", "Bash(\"C:/Users/sleek/AppData/Local/Apps/Tcl903/bin/tclsh.exe\" src/tests/runtests.tcl *)", "Bash(./bin/punk91.exe src/tests/runtests.tcl *)", "Bash(tclsh src/make.tcl *)", "Bash(tclsh90 src/make.tcl *)", "Bash(tclsh87 src/make.tcl *)", "Bash(/c/Users/sleek/AppData/Local/Apps/Tcl903/bin/tclsh90 src/make.tcl *)", "Bash(\"C:/Users/sleek/AppData/Local/Apps/Tcl903/bin/tclsh.exe\" src/make.tcl *)", "Bash(./bin/punk91.exe src/make.tcl *)", "Bash(./bin/punk902z.exe src/make.tcl *)", "Bash(./bin/punksys.exe src/make.tcl *)", "Bash(tclsh scriptlib/developer/goals_lint.tcl *)", "Bash(tclsh90 scriptlib/developer/goals_lint.tcl *)", "Bash(/c/Users/sleek/AppData/Local/Apps/Tcl903/bin/tclsh90 scriptlib/developer/goals_lint.tcl *)", "Bash(\"C:/Users/sleek/AppData/Local/Apps/Tcl903/bin/tclsh.exe\" scriptlib/developer/goals_lint.tcl *)", "PowerShell(tclsh scriptlib/developer/goals_lint.tcl *)", "PowerShell(tclsh90 scriptlib/developer/goals_lint.tcl *)", "PowerShell(& \"C:\\Users\\sleek\\AppData\\Local\\Apps\\Tcl903\\bin\\tclsh90.exe\" scriptlib/developer/goals_lint.tcl *)", "PowerShell(tclsh src/make.tcl *)", "PowerShell(tclsh90 src/make.tcl *)", "PowerShell(& \"C:\\Users\\sleek\\AppData\\Local\\Apps\\Tcl903\\bin\\tclsh90.exe\" src/make.tcl *)", "PowerShell(& c:\\repo\\jn\\shellspy\\bin\\punk902z.exe src/make.tcl *)", "PowerShell(Get-Process *)", "PowerShell(git status *)", "PowerShell(git log *)", "PowerShell(git diff *)" ] }, "hooks": { "PreToolUse": [ { "matcher": "Bash|PowerShell", "hooks": [ { "type": "command", "command": "cmd=$(jq -r '.tool_input.command // empty'); if printf '%s' \"$cmd\" | grep -qiE '(^|[|;&(]|\\$\\()[[:space:]]*[^|;&[:space:]]*tclsh[0-9.]*(\\.exe)?\"?[[:space:]]+(-encoding[[:space:]]+[^[:space:]]+[[:space:]]+)?-e([[:space:]]|$)'; then printf '%s' '{\"hookSpecificOutput\":{\"hookEventName\":\"PreToolUse\",\"permissionDecision\":\"deny\",\"permissionDecisionReason\":\"tclsh has no -e one-liner flag. An argument starting with - is not treated as a script file: all args land in $argv and tclsh reads commands from stdin instead (hangs forever at an interactive prompt on a console; silently ignores the -e script when stdin is piped). Write the code to a temp .tcl file and run: tclsh path/to/file.tcl - or pipe the script via stdin. See AGENTS.md User Preferences.\"}}'; fi", "shell": "bash", "timeout": 15, "statusMessage": "Checking for tclsh -e misuse" } ] } ] } }