#!/bin/bash
# Thin wrapper that delegates to @quantiya/codevibe-claude-plugin
# Resolves the actual binary from the installed dependency

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
DELEGATE="$SCRIPT_DIR/../node_modules/@quantiya/codevibe-claude-plugin/bin/codevibe-claude"

if [ ! -f "$DELEGATE" ]; then
  echo "Error: @quantiya/codevibe-claude-plugin not found. Try reinstalling: npm install -g @quantiya/codevibe" >&2
  exit 1
fi

exec "$DELEGATE" "$@"
