Skip to content

Built by a PhD whose memory was failing, whose diet was a mess, and whose anxiety had its own agenda. Most second brain tools ignore the fact that your brain doesn't work in isolation: your body and your mental health are part of the system too. This crew handles all three: knowledge, nutrition, and mental wellness.

Shell
931 B
Raw Blame
#!/usr/bin/env bash
# =============================================================================
# Generated by adapters/claude-code/adapter.sh — do not edit.
# Wrapper for hook: __HOOK_NAME__
# Reads Claude Code native PreToolUse/PostToolUse/Notification JSON from stdin,
# transforms it into the neutral schema, and pipes the result to __HOOK_NAME__.sh.
# =============================================================================
set -eo pipefail

INPUT=$(cat)
HOOK_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

# Translate CC native fields to the neutral schema
NEUTRAL=$(echo "$INPUT" | jq -c '{
  event: "__EVENT_NAME__",
  tool: (.tool_name // ""),
  args: (.tool_input // {title: .title, message: .message}),
  session_id: (.session_id // ""),
  cwd: (.cwd // ""),
  framework: "claude-code",
  platform_dir: ".claude",
  dispatcher_name: "CLAUDE.md"
}')

echo "$NEUTRAL" | bash "$HOOK_DIR/__HOOK_NAME__.sh"