From: Eilon Lipton Date: Tue, 2 Jul 2019 20:36:22 +0000 (-0700) Subject: Make building easier on Windows by setting PowerShell execution policy (attempt 2... X-Git-Tag: accepted/tizen/5.5/unified/20200421.150457~316^2^2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cd699094ba340b78c0de1b6b93aeb36906e8be7e;p=platform%2Fcore%2Fcsapi%2Fxsf.git Make building easier on Windows by setting PowerShell execution policy (attempt 2) (#6755) * Make building easier on Windows by setting PowerShell execution policy * Update build.cake to reference cmd as well as ps1 * remove . on instructions --- diff --git a/build.cake b/build.cake index 0e8541f..c52d483 100644 --- a/build.cake +++ b/build.cake @@ -6,11 +6,14 @@ // examples /* +Windows CMD: +build.cmd -Target NugetPack +build.cmd -Target NugetPack -ScriptArgs '-packageVersion="9.9.9-custom"' + +PowerShell: ./build.ps1 -Target NugetPack ./build.ps1 -Target NugetPack -ScriptArgs '-packageVersion="9.9.9-custom"' - - */ ////////////////////////////////////////////////////////////////////// // ADDINS diff --git a/build.cmd b/build.cmd new file mode 100644 index 0000000..4dded3f --- /dev/null +++ b/build.cmd @@ -0,0 +1,6 @@ +@ECHO OFF +SETLOCAL +PowerShell -NoProfile -NoLogo -ExecutionPolicy Bypass -Command "[System.Threading.Thread]::CurrentThread.CurrentCulture = ''; [System.Threading.Thread]::CurrentThread.CurrentUICulture = ''; try { & '%~dp0build.ps1' %*; exit $LASTEXITCODE } catch { write-host $_; exit 1 }" +SET exit_code=%ERRORLEVEL% +ECHO build.cmd completed +EXIT /b %exit_code% \ No newline at end of file