#!/bin/bash # Quick uv build and test script for Enhanced MCP Tools set -e # Exit on any error echo "๐Ÿš€ Enhanced MCP Tools - uv Build & Test Script" echo "==============================================" # Check uv is available if ! command -v uv &> /dev/null; then echo "โŒ uv is not installed. Install with: pip install uv" exit 1 fi echo "โœ… uv version: $(uv --version)" # Clean previous builds echo "๐Ÿงน Cleaning previous builds..." rm -rf dist/ build/ *.egg-info/ # Build package echo "๐Ÿ“ฆ Building package with uv..." uv build # Check build artifacts echo "๐Ÿ“‹ Build artifacts:" ls -la dist/ # Test installation in clean environment echo "๐Ÿงช Testing installation..." uv venv test-build --quiet source test-build/bin/activate # Install from wheel echo "๐Ÿ“ฅ Installing from wheel..." uv pip install dist/*.whl --quiet # Test imports echo "๐Ÿ” Testing imports..." python -c " from enhanced_mcp import create_server, MCPToolServer from enhanced_mcp.sneller_analytics import SnellerAnalytics from enhanced_mcp.git_integration import GitIntegration print('โœ… All core imports successful') " # Test enhanced dependencies echo "๐Ÿš€ Testing enhanced dependencies..." uv pip install "enhanced-mcp-tools[enhanced]" --find-links dist/ --quiet python -c " import aiofiles, watchdog, psutil, requests print('โœ… Enhanced dependencies installed and working') " # Test CLI entry point if command -v enhanced-mcp &> /dev/null; then echo "โœ… enhanced-mcp CLI command available" else echo "โš ๏ธ enhanced-mcp CLI command not found (may need PATH update)" fi # Cleanup deactivate rm -rf test-build/ echo "" echo "๐ŸŽ‰ SUCCESS! Enhanced MCP Tools built and tested successfully with uv" echo "" echo "๐Ÿ“ฆ Built artifacts:" echo " - dist/enhanced_mcp_tools-1.0.0-py3-none-any.whl" echo " - dist/enhanced_mcp_tools-1.0.0.tar.gz" echo "" echo "๐Ÿ“ฅ Install with:" echo " uv pip install dist/*.whl # Core" echo " uv pip install dist/*.whl[enhanced] # Enhanced" echo " uv pip install dist/*.whl[full] # Full" echo ""