23 lines
564 B
Batchfile
23 lines
564 B
Batchfile
@echo off
|
|
setlocal
|
|
chcp 65001 >nul
|
|
cd /d "%~dp0"
|
|
|
|
REM Utilise le lanceur "py" s'il existe (recommande), sinon "python" du PATH
|
|
where py >nul 2>nul
|
|
if %errorlevel%==0 (
|
|
set "PY=py -3"
|
|
) else (
|
|
set "PY=python"
|
|
)
|
|
|
|
if not exist .venv (
|
|
echo Premiere installation ^(environnement Python + Chromium^), patientez quelques minutes...
|
|
%PY% -m venv .venv
|
|
.venv\Scripts\python.exe -m pip install --upgrade pip
|
|
.venv\Scripts\python.exe -m pip install -r requirements.txt
|
|
.venv\Scripts\python.exe -m playwright install chromium
|
|
)
|
|
|
|
.venv\Scripts\python.exe app.py
|