39 lines
1.5 KiB
Batchfile
39 lines
1.5 KiB
Batchfile
@echo off
|
|
REM ================================================================
|
|
REM mkpyproject.bat - Standard Python Projekt Template erstellen
|
|
REM ================================================================
|
|
REM Verwendung: mkpyproject.bat <projektname> [zielverzeichnis]
|
|
REM ================================================================
|
|
|
|
REM Pfad zum Python-Skript (relativ zu diesem Skript)
|
|
set "TOOLS_LIB=%~dp0..\lib"
|
|
|
|
REM Pruefen ob Python verfuegbar ist
|
|
py --version >nul 2>&1
|
|
if errorlevel 1 (
|
|
python --version >nul 2>&1
|
|
if errorlevel 1 (
|
|
echo.
|
|
echo ================================================================
|
|
echo FEHLER: Kein Python-Interpreter gefunden!
|
|
echo ================================================================
|
|
echo.
|
|
echo Weder 'py' noch 'python' konnten ausgefuehrt werden.
|
|
echo.
|
|
echo Bitte sicherstellen, dass Python installiert ist und der
|
|
echo Pfad zur python.exe in der PATH-Umgebungsvariable enthalten ist.
|
|
echo.
|
|
echo 1. Python installieren: https://www.python.org/downloads/
|
|
echo 2. Bei der Installation "Add Python to PATH" aktivieren
|
|
echo 3. Oder manuell den Pfad hinzufuegen:
|
|
echo set PATH=%%PATH%%;C:\Python312
|
|
echo.
|
|
echo ================================================================
|
|
exit /b 1
|
|
)
|
|
python "%TOOLS_LIB%\mkpyproject.py" %*
|
|
goto :eof
|
|
)
|
|
|
|
py "%TOOLS_LIB%\mkpyproject.py" %*
|