By takahirom
Auto-discovered marketplace from takahirom/android-analyze-file-hook
npx claudepluginhub takahirom/android-analyze-file-hookClaude Code PostToolUse hook that runs `android studio analyze-file` after edits and feeds back only ERRORs to the agent (warnings are ignored).
A Claude Code PostToolUse hook plugin. After every file edit, it runs
android studio analyze-file and feeds back to the agent only when there are
ERRORs (WARNINGs are ignored).
Android Studio's Agent Mode has a "file critic" that runs around edits, but other agents (such as Claude Code) don't. This plugin fills that gap.
android studio analyze-file exits 0 even when it reports ERRORs/WARNINGs, so
the exit code can't be used. We parse the output for ERROR in lines instead.grep / awk / sed only — no jq).android CLI (on PATH or at ~/.local/bin/android). See https://developer.android.com/tools/agents.READY in android studio check)..kt / .kts / .java./plugin marketplace add takahirom/android-analyze-file-hook
/plugin install android-analyze-file-hook@android-analyze-file-hook
Restart Claude Code after installing so the hook is loaded.
Place the script and register the hook in settings.json.
mkdir -p ~/.claude/hooks
curl -o ~/.claude/hooks/analyze-file-hook.sh \
https://raw.githubusercontent.com/takahirom/android-analyze-file-hook/main/hooks/analyze-file-hook.sh
chmod +x ~/.claude/hooks/analyze-file-hook.sh
Add to ~/.claude/settings.json (or the project's .claude/settings.json):
{
"hooks": {
"PostToolUse": [
{
"matcher": "Edit|Write|MultiEdit",
"hooks": [
{ "type": "command", "command": "~/.claude/hooks/analyze-file-hook.sh" }
]
}
]
}
}
analyze-file found 2 error(s) in .../HookSmokeTest.kt (warnings omitted):
- L4: Parameter name expected
- L4: Expecting comma or ')'
./test.sh
Injects a fake android (canned output) at the front of PATH and verifies
end-to-end (ERROR → exit 2 / WARNING only → exit 0 / non-source, missing file,
outside project → exit 0).
READY rows
of android studio check. With multiple worktrees open, a file may resolve to a
different worktree's project name.android studio analyze-file)7-day visitors to each marketplace page
Anthropic example skills
Anthropic's Claude Code plugins, installed from the claude-plugins-official repository
Ultra-compressed communication mode. Shortens prose while preserving technical terms, code, commands, and exact errors.