#!/usr/bin/env bash # # Claude Code PreToolUse hook, for AskUserQuestion only: a "Shall it land?" # card waits for a picture shown since the person last answered, or a line # saying why there is none. The work is `midas hook pre-tool-use` (src/hook.rs). # FAILS OPEN: a midas too old to know it, or no hub, lets every card through. [ -f "$HOME/.config/midas/hub.env" ] || exit 0 M=$HOME/.local/bin/midas; [ -x "$M" ] || M=$(command -v midas) || exit 0 "$M" hook pre-tool-use 2>/dev/null exit 0