update
This commit is contained in:
60
APP/spotify-recorder - Kopie/Spotify Recorder.bat
Normal file
60
APP/spotify-recorder - Kopie/Spotify Recorder.bat
Normal file
@@ -0,0 +1,60 @@
|
||||
@echo off
|
||||
title Spotify Recorder
|
||||
cd /d "%~dp0"
|
||||
|
||||
echo.
|
||||
echo ====================================
|
||||
echo Spotify Recorder - Setup
|
||||
echo ====================================
|
||||
echo.
|
||||
|
||||
:: Python pruefen
|
||||
where python >nul 2>&1
|
||||
if %errorlevel% neq 0 (
|
||||
echo [FEHLER] Python wurde nicht gefunden!
|
||||
echo.
|
||||
echo Bitte installiere Python von:
|
||||
echo https://www.python.org/downloads/
|
||||
echo.
|
||||
echo WICHTIG: Haken bei "Add Python to PATH" setzen!
|
||||
echo.
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
:: Virtuelle Umgebung erstellen (nur beim ersten Start)
|
||||
if not exist "venv\Scripts\activate.bat" (
|
||||
echo [1/2] Erstelle Python-Umgebung...
|
||||
python -m venv venv
|
||||
if %errorlevel% neq 0 (
|
||||
echo.
|
||||
echo [FEHLER] Umgebung konnte nicht erstellt werden.
|
||||
echo.
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
echo Fertig.
|
||||
echo.
|
||||
)
|
||||
|
||||
:: Umgebung aktivieren
|
||||
call venv\Scripts\activate.bat
|
||||
|
||||
:: Pakete pruefen und installieren
|
||||
echo [2/2] Pruefe Pakete...
|
||||
pip install -r requirements.txt --quiet --disable-pip-version-check
|
||||
if %errorlevel% neq 0 (
|
||||
echo.
|
||||
echo [FEHLER] Paket-Installation fehlgeschlagen.
|
||||
echo Hast du eine Internetverbindung?
|
||||
echo.
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
echo Alles bereit!
|
||||
echo.
|
||||
echo App wird gestartet...
|
||||
|
||||
:: App ohne Konsole starten
|
||||
start "" "%~dp0venv\Scripts\pythonw.exe" "%~dp0main.py"
|
||||
Reference in New Issue
Block a user