.PHONY: install test test-plugin doctor verify clean lint format build-plugin sync-plugin-repo uninstall-legacy help # Installation (local source, editable) - RECOMMENDED install: @echo "๐Ÿ”ง Installing SuperClaude Framework (development mode)..." uv pip install -e ".[dev]" @echo "" @echo "โœ… Installation complete!" @echo " Run 'make verify' to check installation" # Run tests test: @echo "Running tests..." uv run pytest # Test pytest plugin loading test-plugin: @echo "Testing pytest plugin auto-discovery..." @uv run python -m pytest --trace-config 2>&1 | grep -A2 "registered third-party plugins:" | grep superclaude && echo "โœ… Plugin loaded successfully" || echo "โŒ Plugin not loaded" # Run doctor command doctor: @echo "Running SuperClaude health check..." @uv run superclaude doctor # Verify Phase 1 installation verify: @echo "๐Ÿ” Phase 1 Installation Verification" @echo "======================================" @echo "" @echo "1. Package location:" @uv run python -c "import superclaude; print(f' {superclaude.__file__}')" @echo "" @echo "2. Package version:" @uv run superclaude --version | sed 's/^/ /' @echo "" @echo "3. Pytest plugin:" @uv run python -m pytest --trace-config 2>&1 | grep "registered third-party plugins:" -A2 | grep superclaude | sed 's/^/ /' && echo " โœ… Plugin loaded" || echo " โŒ Plugin not loaded" @echo "" @echo "4. Health check:" @uv run superclaude doctor | grep "SuperClaude is healthy" > /dev/null && echo " โœ… All checks passed" || echo " โŒ Some checks failed" @echo "" @echo "======================================" @echo "โœ… Phase 1 verification complete" # Linting lint: @echo "Running linter..." uv run ruff check . # Format code format: @echo "Formatting code..." uv run ruff format . # Clean build artifacts clean: @echo "Cleaning build artifacts..." rm -rf build/ dist/ *.egg-info find . -type d -name __pycache__ -exec rm -rf {} + find . -type d -name .pytest_cache -exec rm -rf {} + find . -type d -name .ruff_cache -exec rm -rf {} + PLUGIN_DIST := dist/plugins/superclaude PLUGIN_REPO ?= ../SuperClaude_Plugin .PHONY: build-plugin build-plugin: ## Build SuperClaude plugin artefacts into dist/ @echo "๐Ÿ› ๏ธ Building SuperClaude plugin from unified sources..." @uv run python scripts/build_superclaude_plugin.py .PHONY: sync-plugin-repo sync-plugin-repo: build-plugin ## Sync built plugin artefacts into ../SuperClaude_Plugin @if [ ! -d "$(PLUGIN_REPO)" ]; then \ echo "โŒ Target plugin repository not found at $(PLUGIN_REPO)"; \ echo " Set PLUGIN_REPO=/path/to/SuperClaude_Plugin when running make."; \ exit 1; \ fi @echo "๐Ÿ“ฆ Syncing artefacts to $(PLUGIN_REPO)..." @rsync -a --delete $(PLUGIN_DIST)/agents/ $(PLUGIN_REPO)/agents/ @rsync -a --delete $(PLUGIN_DIST)/commands/ $(PLUGIN_REPO)/commands/ @rsync -a --delete $(PLUGIN_DIST)/hooks/ $(PLUGIN_REPO)/hooks/ @rsync -a --delete $(PLUGIN_DIST)/scripts/ $(PLUGIN_REPO)/scripts/ @rsync -a --delete $(PLUGIN_DIST)/skills/ $(PLUGIN_REPO)/skills/ @rsync -a --delete $(PLUGIN_DIST)/.claude-plugin/ $(PLUGIN_REPO)/.claude-plugin/ @echo "โœ… Sync complete." # Translate README to multiple languages using Neural CLI translate: @echo "๐ŸŒ Translating README using Neural CLI (Ollama + qwen2.5:3b)..." @if [ ! -f ~/.local/bin/neural-cli ]; then \ echo "๐Ÿ“ฆ Installing neural-cli..."; \ mkdir -p ~/.local/bin; \ ln -sf ~/github/neural/src-tauri/target/release/neural-cli ~/.local/bin/neural-cli; \ echo "โœ… neural-cli installed to ~/.local/bin/"; \ fi @echo "" @echo "๐Ÿ‡จ๐Ÿ‡ณ Translating to Simplified Chinese..." @~/.local/bin/neural-cli translate README.md --from English --to "Simplified Chinese" --output README-zh.md @echo "" @echo "๐Ÿ‡ฏ๐Ÿ‡ต Translating to Japanese..." @~/.local/bin/neural-cli translate README.md --from English --to Japanese --output README-ja.md @echo "" @echo "โœ… Translation complete!" @echo "๐Ÿ“ Files updated: README-zh.md, README-ja.md" # Show help help: @echo "SuperClaude Framework - Available commands:" @echo "" @echo "๐Ÿš€ Quick Start:" @echo " make install - Install in development mode (RECOMMENDED)" @echo " make verify - Verify installation is working" @echo "" @echo "๐Ÿ”ง Development:" @echo " make test - Run test suite" @echo " make test-plugin - Test pytest plugin auto-discovery" @echo " make doctor - Run health check" @echo " make lint - Run linter (ruff check)" @echo " make format - Format code (ruff format)" @echo " make clean - Clean build artifacts" @echo "" @echo "๐Ÿ”Œ Plugin Packaging:" @echo " make build-plugin - Build SuperClaude plugin artefacts into dist/" @echo " make sync-plugin-repo - Sync artefacts into ../SuperClaude_Plugin" @echo "" @echo "๐Ÿ“š Documentation:" @echo " make translate - Translate README to Chinese and Japanese" @echo "" @echo "๐Ÿงน Cleanup:" @echo " make uninstall-legacy - Remove old SuperClaude files from ~/.claude" @echo " make help - Show this help message" # Remove legacy SuperClaude files from ~/.claude directory uninstall-legacy: @echo "๐Ÿงน Cleaning up legacy SuperClaude files..." @bash scripts/uninstall_legacy.sh @echo ""