31 lines
680 B
Bash
Executable File
31 lines
680 B
Bash
Executable File
#!/bin/bash
|
|
# Clean all Python cache files
|
|
|
|
set -e
|
|
|
|
echo "Cleaning Python cache files..."
|
|
|
|
# Find and remove __pycache__ directories
|
|
find . -type d -name "__pycache__" -exec rm -rf {} + 2>/dev/null || true
|
|
|
|
# Find and remove .pyc files
|
|
find . -type f -name "*.pyc" -delete 2>/dev/null || true
|
|
|
|
# Find and remove .pyo files
|
|
find . -type f -name "*.pyo" -delete 2>/dev/null || true
|
|
|
|
# Clean pytest cache
|
|
rm -rf .pytest_cache/ 2>/dev/null || true
|
|
|
|
# Clean mypy cache
|
|
rm -rf .mypy_cache/ 2>/dev/null || true
|
|
|
|
# Clean ruff cache
|
|
rm -rf .ruff_cache/ 2>/dev/null || true
|
|
|
|
# Clean coverage
|
|
rm -f .coverage 2>/dev/null || true
|
|
rm -rf htmlcov/ 2>/dev/null || true
|
|
|
|
echo "✓ Cache cleaned"
|