-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild-rel-win-dependent.bat
25 lines (20 loc) · 1.04 KB
/
build-rel-win-dependent.bat
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
@echo off
SETLOCAL
REM %~dp0 is a batch script implicit variable.
REM The variable is a string which is the full path to THE DIRECTORY WHICH CONTAINS THIS BATCH SCRIPT.
@cd /d %~dp0
SET "DOTNET_CLI_TELEMETRY_OPTOUT=1"
SET "MSBUILDDISABLENODEREUSE=1"
REM If folder "sdk" exist here, use the local sdk instead.
IF EXIST "%~dp0\sdk" (
SET "DOTNET_ROOT=%~dp0\sdk"
SET "PATH=%DOTNET_ROOT%;%PATH%"
)
REM You can switch between:
REM - Non-windows or Linux: "net7.0" or "net8.0"
REM - Windows: "net7.0-windows" or "net8.0-windows"
REM You can also switch to .NET8 SDK by changing the "net7.0" to "net8.0", or "net7.0-windows" to "net8.0-windows" value of the "-f" argument
REM Recommended windows SDKs since they're more optimal.
REM As of writing this script, select .NET7 because CsWin32 doesn't generate compatible code with .NET8 SDK v1.0.0-rc1
dotnet.exe publish -r win-x64 -f net8.0-windows --no-self-contained -p:PublishAot=false -p:PublishReadyToRun=true -p:PublishSingleFile=true -c Release -o "release\windows\dependent" "src\SnowBreakLauncher.csproj"
ENDLOCAL