You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Short agent names: --agent claude, gemini, copilot #1
Every command that takes an agent wants its full id: claude-code, gemini-cli, copilot-cli. People type claude, gemini and copilot. Let those work:
everyhook install examples/block-force-push.mjs --agent claude,gemini,copilot
everyhook list --agent claude
everyhook explain gemini pre-tool
everyhook bench examples/block-force-push.mjs --agent copilot --event pre-tool
Accepted short names: claude for claude-code, gemini for gemini-cli, copilot for copilot-cli. codex and cursor are already whole.
The long name always wins when both could apply, and every output (text and --json) keeps using the long names. Nothing is written into a configuration file with a short name: install still writes --agent claude-code in the command line it adds.
An unknown name is the usage error it is today (exit 2): unknown agent "vim" (claude-code, codex, gemini-cli, copilot-cli, cursor).
run accepts the short names too (run --agent claude --event pre-tool -- hook.mjs), so a person can try a hook by hand.
Where
src/contract.mjs: an AGENT_ALIASES map and a function agentId(name) that returns the long id or null.
src/cli.mjs: parseArgs uses it for --agent and for the first positional argument of explain.
test/cli.test.mjs: the short names for install --dry-run --json, list, explain, bench, run; the error for an unknown name; that the JSON output uses the long names.
README.md: one sentence under "Use"; CHANGELOG.md under Unreleased.
Why
The long ids are what the agents are called in the files everyhook writes and in the JSON it reads, so they stay. The short ones are only for the keyboard.
Activity
1.1.0: short agent names