diff --git a/Makefile b/Makefile index 492b9b2..f67e670 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ # Makefile for Kaizen Agentic development tasks -.PHONY: help setup-complete setup-structure setup-python setup-tools setup-docs setup-tests setup-verify ensure-project-structure install-dev standards-check standards-fix standards-test test test-all build clean lint format venv-status agents-list agents-update agents-validate agents-status agents-install-cli release-check release-prepare release-test release-publish release-finalize release-rollback +.PHONY: help setup-complete setup-structure setup-python setup-tools setup-docs setup-tests setup-verify ensure-project-structure install-dev install-local standards-check standards-fix standards-test test test-all build clean lint format venv-status agents-list agents-update agents-validate agents-status agents-install-cli release-check release-prepare release-test release-publish release-finalize release-rollback # Variables VENV = .venv @@ -24,6 +24,7 @@ help: @echo " setup-tests - Create testing infrastructure" @echo " setup-verify - Verify complete setup functionality" @echo " install-dev - Install package in development mode" + @echo " install-local - Install from locally built package (test PyPI installation)" @echo " venv-status - Check if venv is active" @echo "" @echo "Standards Compliance:" @@ -84,6 +85,49 @@ install-dev: $(VENV)/bin/activate @$(VENV_PIP) install -e . @echo "โœ… Package installed in development mode" +# Install from locally built package (test PyPI installation) +install-local: $(VENV)/bin/activate + @echo "๐Ÿ“ฆ Installing from locally built package..." + @if [ ! -d "dist" ] || [ -z "$$(ls dist/*.whl 2>/dev/null)" ]; then \ + echo "โŒ No wheel package found in dist/"; \ + echo " Run 'make build' or 'make release-prepare' first"; \ + exit 1; \ + fi; \ + WHEEL_FILE=$$(ls dist/*.whl | head -1); \ + VERSION=$$(basename "$$WHEEL_FILE" | sed 's/kaizen_agentic-\(.*\)-py3.*/\1/'); \ + echo " Installing kaizen-agentic v$$VERSION from local wheel..."; \ + $(VENV_PIP) install --upgrade pip; \ + $(VENV_PIP) uninstall -y kaizen-agentic 2>/dev/null || true; \ + $(VENV_PIP) install "$$WHEEL_FILE" --force-reinstall; \ + echo ""; \ + echo "โœ… Local package installed successfully!"; \ + echo " Version: $$VERSION"; \ + echo " Package contents:"; \ + $(VENV_PIP) show kaizen-agentic; \ + echo ""; \ + echo "๐Ÿงช Testing installation..."; \ + if $(VENV_PYTHON) -c "import kaizen_agentic; print(f'โœ… Import successful: kaizen_agentic v{kaizen_agentic.__version__}')" 2>/dev/null; then \ + echo " โœ… Package import test passed"; \ + else \ + echo " โŒ Package import test failed"; \ + $(VENV_PYTHON) -c "import kaizen_agentic" 2>&1 || true; \ + fi; \ + if $(VENV)/bin/kaizen-agentic --version 2>/dev/null; then \ + echo " โœ… CLI command test passed"; \ + else \ + echo " โŒ CLI command test failed"; \ + $(VENV)/bin/kaizen-agentic --version 2>&1 || true; \ + fi; \ + if $(VENV)/bin/kaizen-agentic list 2>/dev/null | head -5; then \ + echo " โœ… CLI functionality test passed"; \ + else \ + echo " โŒ CLI functionality test failed"; \ + fi; \ + echo ""; \ + echo "๐Ÿ’ก Usage:"; \ + echo " source $(VENV)/bin/activate"; \ + echo " kaizen-agentic --help" + # Ensure proper Python project structure exists ensure-project-structure: @echo "๐Ÿ” Ensuring proper Python project structure..."