Repository navigation
fix(hooks): match static words by their single-quoted form in precise command rules - #147
Conversation
… command rules Closes #143 Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
|
@codex review |
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Review summaryNo P0 or P1 findings, and no inline comments. What I checked:
Not blocking, and older than this PR: a word that starts with I could not run the tests here: the sandbox would not run pytest without approval. 🤖 Generated with Claude Code |
🤖 I have created a release *beep* *boop* --- ## [0.1.1](v0.1.0...v0.1.1) (2026-11-11) ### Features * **hooks:** judge session changes with jev-lint model rules at Stop ([#150](#150)) ([946e976](946e976)) ### Bug Fixes * **hooks:** ask for zsh's $=name and $~name expansions ([#152](#152)) ([9255c87](9255c87)) * **hooks:** judge a ~user path by the secret-path rules of the own home ([#129](#129)) ([64221f6](64221f6)) * **hooks:** match static words by their single-quoted form in precise command rules ([#147](#147)) ([c432a20](c432a20)) * **hooks:** run verification tools through the flake dev shell ([#132](#132)) ([63dd2f5](63dd2f5)) * **hooks:** start trusted model-rule programs and send only in-repository regular files ([#156](#156)) ([183496b](183496b)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: furedea-release[bot] <353651101+furedea-release[bot]@users.noreply.github.com>
概要
guard_command.pyの精密ルールが,クォートの書き方だけが違う同じ静的な値(-f body="Fixed."など)を「確認」に回していたため,ADR-0015 の①に沿って判定を直す.'…',"…",\エスケープ)を,各部分を一定の形(シングルクォート)に書き直した正規形で並べ直し,パターンを生の語と正規形の両方に照合する(どちらかが一致すれば allow)$,バッククォート,\,!を含むダブルクォートなど)と動的な語は従来どおり生の語だけで照合するため,ask のままallowed_commands.jsonにルールは追加していないCloses #143
判定の変化
gh api …/replies -f body="Fixed."gh api …/replies -f body=Fixed\.curl -s -w "status" http://localhost/-w 'status'と同一の値.既存の ask テスト 1 行を allow テストへ移動)gh run list --commit "$sha"gh run list --commit $shagh run list --commit $(git rev-parse HEAD)同一コマンド内の固定値代入(
sha=…; gh … $sha)は 2026-11-11 の決定どおり扱わず,ADR-0015 に既知の穴として追記した.テスト
tests/hooks/test_quote_normalization.pyを追加(allow 側と,展開・!・バッククォート・エスケープ・未クォート変数・コマンド置換・代入が ask のままであること)tests/hooksはtest_formatter_config.py(サンドボックスがplugins.dprint.devを遮断するため実行不可)を除いて通過🤖 Generated with Claude Code