Files
ReminderOrganizer/release.bat

48 lines
1.3 KiB
Batchfile
Raw Normal View History

@echo off
cd /d "%~dp0"
echo.
echo ============================================
echo ReminderOrganizer - Release Builder
echo ============================================
echo.
echo [1/4] Loesche alte Dateien...
if exist "publish" rmdir /s /q "publish"
if exist "ReminderOrganizer.zip" del "ReminderOrganizer.zip"
echo [2/4] Baue Single-File EXE...
dotnet publish -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:IncludeAllContentForSelfExtract=true -o publish
if errorlevel 1 (
echo.
echo *** FEHLER beim Bauen! ***
pause
exit /b 1
)
echo [3/4] Kopiere Locales Ordner...
xcopy /E /I /Y "Locales" "publish\Locales" >nul
echo [4/4] Erstelle ZIP Datei...
powershell -Command "Compress-Archive -Path 'publish\ReminderOrganizer.exe', 'publish\Locales\*' -DestinationPath 'ReminderOrganizer.zip' -Force"
if errorlevel 1 (
echo.
echo *** FEHLER beim ZIP erstellen! ***
pause
exit /b 1
)
echo.
echo ============================================
echo FERTIG!
echo ReminderOrganizer.zip wurde erstellt.
echo ============================================
echo Inhalt:
echo - ReminderOrganizer.exe
echo - Locales\de.json (Deutsch)
echo - Locales\en.json (English)
echo ============================================
echo.
pause