1
0
Fork 0
mirror of https://github.com/VSadov/Satori.git synced 2025-06-07 19:17:05 +09:00
Satori/dotnet.cmd
Viktor Hofer f5957b1bae
Move dotnet.cmd/sh helper scripts into the repo root (#672)
* Move dotnet helper scripts to repo root

* Don't swallow InitializeDotNetCli output

* Use temporary file to store sdk location

To avoid a nested process chain in which the inner process then invokes
the host, we instead create a temporary file to store the sdk location.
2019-12-11 21:01:58 +01:00

22 lines
778 B
Batchfile

@echo off
powershell -ExecutionPolicy ByPass -NoProfile -Command "& { . '%~dp0eng\common\tools.ps1'; InitializeDotNetCli $true $true }"
if NOT [%ERRORLEVEL%] == [0] (
echo Failed to install or invoke dotnet... 1>&2
exit /b %ERRORLEVEL%
)
set /p dotnetPath=<%~dp0artifacts\toolset\sdk.txt
:: Clear the 'Platform' env variable for this session, as it's a per-project setting within the build, and
:: misleading value (such as 'MCD' in HP PCs) may lead to build breakage (issue: #69).
set Platform=
:: Don't resolve runtime, shared framework, or SDK from other locations to ensure build determinism
set DOTNET_MULTILEVEL_LOOKUP=0
:: Disable first run since we want to control all package sources
set DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
call "%dotnetPath%\dotnet.exe" %*