-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.bat
More file actions
44 lines (40 loc) · 1.04 KB
/
build.bat
File metadata and controls
44 lines (40 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
@echo off
echo ========================================
echo Meshhessen Client - Build Script
echo ========================================
echo.
echo [1/3] Restoring NuGet packages...
dotnet restore
if %errorlevel% neq 0 (
echo ERROR: NuGet restore failed!
pause
exit /b %errorlevel%
)
echo.
echo [2/3] Building Release configuration...
dotnet build -c Release
if %errorlevel% neq 0 (
echo ERROR: Build failed!
pause
exit /b %errorlevel%
)
echo.
echo [3/3] Publishing standalone EXE...
dotnet publish MeshhessenClient\MeshhessenClient.csproj -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:PublishTrimmed=false -o public
if %errorlevel% neq 0 (
echo ERROR: Publish failed!
pause
exit /b %errorlevel%
)
echo.
echo ========================================
echo Build completed successfully!
echo ========================================
echo.
echo Executable location:
echo %CD%\public\MeshhessenClient.exe
echo.
echo File size:
dir public\MeshhessenClient.exe | find "MeshhessenClient.exe"
echo.
pause