Repository navigation
0.17.0: Antigravity, Droid and Qwen Code targets, PowerShell coverage, and finish lines in compound shell commands - #65
Merged
Merged
Conversation
- Hook payload handling (shell tool names, command fields, host answer formats) moves into one module with direct tests. - Pattern gates share one rule for regex flags. - The receipt module uses the shared git runner. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
if/then/elif/else, for/while/until loops, negation with !, case arms, brace groups, function bodies and PowerShell script blocks no longer hide a finish-line command from the matcher. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
install antigravity writes a fail-closed PreToolUse hook to .agents/hooks.json. gate reads the toolCall payload, judges run_command as a shell command and answers in the host's JSON decision format. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
install droid writes a fail-closed PreToolUse hook on the Execute tool to the file Droid reads: .factory/hooks.json when present, else .factory/settings.json. doctor droid notices when a new hooks.json hides the settings hook. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
install qwen-code writes a fail-closed PreToolUse hook on run_shell_command to .qwen/settings.json, with its timeout in seconds; doctor qwen-code checks it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
install claude-code matches Bash|PowerShell, gate judges a PowerShell call as a shell command, and doctor flags a Bash-only hook. The contrib examples match both tools. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
echo or printf output piped into a shell and a here-string fed to a shell are read as commands; the same text going to any other program stays data. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
install codex writes a commandWindows for each hook: one cmd.exe line that Windows PowerShell 5.1 and cmd.exe both parse. doctor codex flags a hook without it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Invoke-Expression and iex, powershell -EncodedCommand (decoded and judged) and Start-Process with its aliases are read as the commands they run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A segment is also judged with the backslashes a POSIX shell drops removed, so git pu\sh and n\pm publish match; Windows paths keep matching as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each integration's installer, config file, markers and own health rule sit in one row; single-hook installers share one install step; the matcher names the two ways a line runs further commands. No behaviour change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
0.17.0: Antigravity, Droid and Qwen Code targets, PowerShell coverage, and finish lines in compound shell commands See merge request rene/skillgate!4
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
if ...; then git push; fi,for/while/untilloops,! git push,casearms,{ git push; }groups, function bodies and PowerShell script blocks (if (...) { git push },& { ... },Invoke-Command { ... }). Before, the leading keyword or brace hid the command andgateallowed it.skillgate install antigravitygates the Antigravity CLI (agy): a fail-closedPreToolUsehook in.agents/hooks.json, checked bydoctor antigravity.gatereads agy'stoolCallpayload, judgesrun_commandas a shell command and answers in agy's JSON.skillgate install droidgates Factory Droid: a fail-closedPreToolUsehook on theExecutetool, written to.factory/hooks.jsonwhen the project has one and to.factory/settings.jsonotherwise.doctor droidnotices when a newhooks.jsonhides the settings hook.skillgate install qwen-codegates Qwen Code: a fail-closedPreToolUsehook onrun_shell_command(plusgatedTools) in.qwen/settings.json, checked bydoctor qwen-code.install claude-codematchesBash|PowerShelland upgrades a Bash-only hook,gatejudges aPowerShellcall as a shell command, anddoctor claude-codeflags a hook that leaves PowerShell out.echo git push | sh,printf '...' | bash -sand here-strings (bash <<< 'git push'). Text no shell reads stays data.commandWindowsline (cmd.exe /d /s /c "...") that Windows PowerShell 5.1 and cmd.exe both run;doctor codexflags a hook without it.Invoke-Expression/iex(argument or piped script),powershell -EncodedCommand(decoded and judged) andStart-Process(start,saps).git pu\sh,n\pm publish); Windows paths keep matching.Two tidy-up commits keep behaviour unchanged: hook payload handling moves into
src/payload.ts, and each integration's installer, config file and health rules sit in one table insrc/integrations.ts.Evidence
npm ci,npm run build,npm testpass, 297 of 297 tests; coverage 95.86% lines, 88.59% branches, 98.24% functions;node dist/src/cli.js checkpasses.test/release-017.test.tsthat fails on 0.16.1 and passes here, and an end-to-end run of the built CLI against the published 0.16.1 on throwaway repositories with real hook payloads and the installed hook commands.fhe-metricsjob;contrib/fhe-metricsis unchanged.Door
Two-way. New install targets and matcher coverage are additive; the stricter matching only blocks more finish-line forms while gates are unmet, and a release can be reverted or superseded by a patch.
Blast radius
src/command.ts(finish-line matching),src/payload.ts(new: hook payloads and host answers),src/integrations.ts(installers anddoctor),src/cli.ts(help text, payload handling), small internal moves insrc/core.ts,src/git.tsandsrc/receipt.ts, docs, contrib examples and tests. Stored formats (receipts, cache, attestations, decision log) and the policy schema are unchanged. Basec55a51e; the first commit is the tidy-up and reviews on its own.🤖 Generated with Claude Code