diff --git a/requirements-dev.txt b/requirements-dev.txt index 03552f6..621f445 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -10,6 +10,7 @@ black>=23.0.0 mypy>=1.0.0 flake8>=6.0.0 isort>=5.12.0 +pre-commit==4.5.1 # Documentation sphinx>=7.0.0 diff --git a/setup_dev.bat b/setup_dev.bat index f9e615e..19bf0e5 100644 --- a/setup_dev.bat +++ b/setup_dev.bat @@ -60,11 +60,6 @@ if exist "requirements-dev.txt" ( REM Install pre-commit hooks echo. echo 🔧 Setting up pre-commit hooks... -python -m pip install pre-commit --quiet -if errorlevel 1 ( - echo ❌ Error: Failed to install pre-commit - exit /b 1 -) pre-commit install if errorlevel 1 ( echo ❌ Error: Failed to install pre-commit hooks diff --git a/setup_dev.sh b/setup_dev.sh index 71f2bde..847c5f1 100755 --- a/setup_dev.sh +++ b/setup_dev.sh @@ -58,15 +58,8 @@ fi # Install pre-commit hooks echo "" echo "🔧 Setting up pre-commit hooks..." -if command -v pre-commit &> /dev/null || pip show pre-commit &> /dev/null; then - pre-commit install - echo "✅ Pre-commit hooks installed" -else - echo "⚠️ pre-commit not found. Installing..." - pip install pre-commit --quiet - pre-commit install - echo "✅ Pre-commit hooks installed" -fi +pre-commit install +echo "✅ Pre-commit hooks installed" # Verify installation echo ""