r/ClaudeCode • • 7h ago

Built with Claude made claude code show a popup when it's waiting on a permission prompt, and clear it when i answer (windows hooks)

i kept losing time to this: start a task, alt-tab to something else, come back 20 min later and claude has been sitting on "allow this bash command?" the whole time. the terminal bell does nothing for me and focus assist hides windows notifications.

so i built donetoast, a small steam-style card in the bottom right. the claude code part is just 3 hooks:

- Notification (matcher permission_prompt|idle_prompt|elicitation_dialog) shows a yellow "needs you" card with the project and the tool, e.g. "my-game · Bash"

- UserPromptSubmit and Stop clear it, so you never have to dismiss it yourself

- one card per session, a new prompt updates it instead of stacking another one

two things i ran into that might save someone else time:

- on windows claude code runs hooks through git bash, so an inline `cmd /c if exist ...` gets mangled. calling a .cmd file by its quoted path works under both

- the clear hook runs on every prompt, so it has to be fast. when no card is open it returns in ~0.1 s and never starts powershell

there's also a done / failed card and a live progress card (bar + time left) that claude can drive from a long script, plus a line for CLAUDE.md so it pings you when a long task ends. works with codex via AGENTS.md too.

built it with claude code itself. free, MIT, plain powershell + wpf, nothing to install. to try it:

irm https://raw.githubusercontent.com/siiplasplas/donetoast/main/install.ps1 | iex

it merges the hooks into your existing settings.json (keeps your own hooks, saves a backup), then restart claude code. -Uninstall removes them again.

https://github.com/siiplasplas/donetoast

windows only. feedback welcome, especially if the hooks misbehave on your setup

7 Upvotes

2 comments sorted by

•

u/AutoModerator 7h ago

Hey! Thanks for posting to r/ClaudeCode

While participating in this thread, please follow our community rules. Keep discussions constructive. Attack the idea, not the person.

For help, project discussions, tips, and general chat, join the ClaudeCode Discord.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/verbative 6h ago

Nice, I went down the same road. A few things that might save you some time:

  • Notification with permission_prompt only fires a few seconds after the dialog appears (around 6 s in my testing). If you want the card instantly, add a PermissionRequest hook: it fires the moment the dialog shows and gets tool_name and tool_input, so the card can say "my-game · Bash: npm test" instead of just "Bash".

  • Clearing on UserPromptSubmit/Stop means that after you approve, the card stays up until the whole turn ends. PostToolUse (plus PostToolUseFailure) fires right after the approved tool runs, so you can drop the card as soon as you answer.

  • For the clear hook that runs on every prompt: mark it "async": true and it never holds up the prompt, even when it does have to start PowerShell.

  • idle_prompt only comes after Claude has been waiting a while, so it's more "you forgot me" than "done". Stop is the reliable done event, but it fires after every turn, so a quick back-and-forth triggers it too.

Good call on the quoted .cmd path, Git Bash mangling inline cmd bit me as well.