#!/bin/bash
# ai.bot 移行セットアップスクリプト

echo "=== ai.bot Migration Setup ==="

# 1. 新しい設定ディレクトリの作成
echo "Creating new config directory..."
mkdir -p ~/.config/syui/ai/bot/

# 2. スクリプトディレクトリの移動（gitサブモジュール）
if [ -d ~/.config/ai/scpt ]; then
    echo "Copying script directory..."
    cp -r ~/.config/ai/scpt ~/.config/syui/ai/bot/
    echo "Scripts copied to ~/.config/syui/ai/bot/scpt/"
fi

# 3. 設定ファイルの移行（自動的にdata.rsで行われる）
echo "Configuration files will be migrated automatically when used."

# 4. エイリアス設定の提案
echo ""
echo "=== Manual Steps Required ==="
echo ""
echo "1. Add this alias to your shell profile (~/.zshrc, ~/.bashrc, etc.):"
echo "   alias ai='aibot'"
echo ""
echo "2. Install the new binaries:"
echo "   cargo install --path ."
echo ""
echo "3. Or add to PATH:"
echo "   export PATH=\"$(pwd)/target/debug:\$PATH\""
echo ""
echo "4. Update git submodule path if needed:"
echo "   cd ~/.config/syui/ai/bot/scpt"
echo "   git remote -v  # Check current remote"
echo ""
echo "Migration setup complete!"