Dateien nach "/" hochladen

This commit is contained in:
2026-01-21 13:10:28 +00:00
parent 168754137a
commit 86d35fba6b

65
start4.bat Normal file
View File

@@ -0,0 +1,65 @@
@echo off
setlocal enabledelayedexpansion
title Pflanzenprotokoll Starter - Diagnose Modus
set "SELF_NAME=start4.bat"
echo ######################################
echo # Ueberpruefe Systemumgebung...
echo ######################################
REM --- 1. Python-Installation pruefen ---
echo Suche nach Python...
python --version >nul 2>&1
if %errorlevel% NEQ 0 (
echo.
echo ❌ Python wurde nicht gefunden.
echo 🛠️ Versuche Installation via Winget...
REM Wir nutzen hier die ID fuer Python 3.12, die vorhin bei dir funktioniert hat
winget install --id Python.PythonInstallManager -e --source winget --accept-package-agreements --accept-source-agreements
if !errorlevel! EQU 0 (
echo.
echo ✅ Installation erfolgreich eingeleitet!
echo ⚠️ WICHTIG: Schließe dieses Fenster jetzt und starte es NEU.
echo Erst beim Neustart erkennt Windows das neue Python.
call "%SELF_NAME%"
exit
) else (
echo.
echo ❌ Winget-Installation ist fehlgeschlagen.
echo 📥 Oeffne den Microsoft Store manuell fuer dich...
start ms-windows-store://pdp/?ProductId=9NCVDN91XZQP
echo.
echo Bitte installiere Python im Store und starte diese Batch danach neu.
pause
call "%SELF_NAME%"
exit
)
)
REM --- 2. Hauptprogramm starten ---
echo ✅ Python gefunden:
python --version
echo.
echo 🚀 Starte start_app.py...
REM Prüfen ob die Datei überhaupt existiert
if not exist "start_app.py" (
echo ❌ FEHLER: Die Datei 'start_app.py' wurde im Ordner nicht gefunden!
echo Aktueller Ordner: %cd%
pause
exit
)
python start_app.py
if %errorlevel% NEQ 0 (
echo.
echo ❌ Das Python-Programm wurde mit Fehlern beendet (Code: %errorlevel%).
pause
)