#!/bin/bash # SPDX-FileCopyrightText: 2025 Alexander Kalinovsky # # SPDX-License-Identifier: Apache-2.0 # Local CI script to run all checks and a packaging/CLI smoke test set -e echo "๐Ÿš€ Running local CI checks and smoke tests..." echo "๐Ÿ“ฆ Installing dependencies..." uv sync --all-extras --dev echo "๐Ÿ” Running Ruff linting..." uv run ruff check echo "๐ŸŽจ Checking code formatting..." uv run ruff format --check echo "๐Ÿ“ Running MyPy type checking..." uv run mypy . echo "๐Ÿ” Running Reuse linting..." uv run reuse lint echo "๐Ÿงช Running tests..." uv run pytest echo "๐Ÿงช Testing CI workflow steps locally (package build and CLI)..." echo "๐Ÿ“ฆ Building package..." uv build echo "๐Ÿ”ง Testing package installation..." uv pip install dist/*.whl echo "โ“ Testing help command..." uv run quickbot --help echo "๐Ÿš€ Testing CLI functionality..." mkdir -p test_cli_output uv run quickbot init \ --output test_cli_output \ --project-name "Local Test" \ --description "Local Test Description" \ --author "Local Test" \ --license-name MIT \ --no-include-alembic \ --no-include-i18n \ --no-interactive echo "๐Ÿ“ Checking generated files..." ls -la test_cli_output/ echo "๐Ÿ“„ Generated pyproject.toml:" cat test_cli_output/pyproject.toml echo "๐Ÿงน Cleaning up..." rm -rf test_cli_output rm -rf dist/* echo "โœ… All checks and smoke tests passed!"