Files
My-Brain-Is-Full-Crew/hooks/notify.sh
lh f66f4f6566 Add Hey CLI as alternative email backend for Postman (#14)
* Add Hey CLI support as alternative email backend

The Postman agent now supports two email backends:
- Hey (hey CLI) for Hey.com accounts with pre-sorted mailboxes
- GWS (gws CLI) for Gmail/Google Workspace accounts

Hey's mailbox model (Imbox, Feed, Paper Trail, Reply Later,
Set Aside, Bubble Up) is mapped to triage behaviours so the
agent leverages Hey's existing sorting. Calendar operations
remain on GWS.

All MCP function references replaced with CLI equivalents.
No user-specific details in the agent file.

* Update agents in postman.md by removing two roles

Removed descriptions for Food Coach and Wellness Guide agents from the postman documentation.

* Add Hey CLI as email backend across all docs, skills, and references

- Resolve all merge conflicts in postman.md keeping GWS + MCP + Hey
- Apply all 7 review comments from PR #14 (complete mailbox list,
  concrete email_backend setting, consistent template placeholders,
  Hey ID clarification, productivity features disclaimer, deadline
  body scanning, remove user-specific agent references)
- Add Hey CLI alongside GWS/MCP in: README, CLAUDE.md, TERMS_OF_USE,
  DISCLAIMERS, getting-started, gws-setup-guide (renamed sections),
  agents-registry, agents.md, onboarding skill, launchme.sh
- Update all 4 Postman-related skills (email-triage, deadline-radar,
  meeting-prep, weekly-agenda) with Hey CLI commands and backend
  detection
- Expand security section to cover Hey CLI injection vectors
- Keep MCP as read-only fallback for all backends

* Address Copilot review: fix typos, injection rules, platform compat, install hooks

- Fix hey imbox --json typo → hey box imbox --json
- Fix after:{{yesterday}} → newer_than:2d for consistent 48h scan
- Reconcile shell injection rules with hey reply/compose -m (user-approved
  text only, with safe quoting guidance)
- Separate email write ops (GWS/Hey) from calendar write ops (GWS only)
  in TERMS_OF_USE and DISCLAIMERS
- Replace grep -P with POSIX-compatible tab detection in validate-frontmatter
- Add hooks/ and settings.json installation to launchme.sh and updateme.sh
  so .claude/hooks/ paths in settings.json resolve correctly

---------

Co-authored-by: gnekt <dima9610@gmail.com>
2026-03-27 15:51:06 +01:00

23 lines
967 B
Bash
Executable File

#!/usr/bin/env bash
# =============================================================================
# Hook: Desktop Notification (Notification event)
# =============================================================================
# Sends a macOS/Linux desktop notification when Claude Code needs attention.
# Useful during long agent chains that can take several minutes.
#
# macOS: uses osascript (built-in)
# Linux: uses notify-send (install with: sudo apt install libnotify-bin)
# =============================================================================
INPUT=$(cat)
TITLE=$(echo "$INPUT" | jq -r '.title // "Second Brain Crew"' 2>/dev/null)
MESSAGE=$(echo "$INPUT" | jq -r '.message // "Claude needs your attention"' 2>/dev/null)
if [[ "$(uname)" == "Darwin" ]]; then
osascript -e "display notification \"$MESSAGE\" with title \"$TITLE\"" 2>/dev/null
elif command -v notify-send &>/dev/null; then
notify-send "$TITLE" "$MESSAGE" 2>/dev/null
fi
exit 0