2
0

jenkins.build.init.cmd 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. ::-------------------------------------------------------------------------------------------------------
  2. :: Copyright (C) Microsoft. All rights reserved.
  3. :: Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. ::-------------------------------------------------------------------------------------------------------
  5. @echo off
  6. if not "%JENKINS_BUILD%" == "True" (
  7. echo This script should be run under a Jenkins Build environment
  8. exit /b 2
  9. )
  10. set REPO_ROOT=%~dp0\..
  11. set JENKINS_BUILD_ARGS=
  12. set JENKINS_FORCE_MSBUILD_VERSION=
  13. :ContinueArgParse
  14. if not [%1]==[] (
  15. if [%1]==[msbuild14] (
  16. set JENKINS_FORCE_MSBUILD_VERSION=%1
  17. goto :ContinueArgParseEnd
  18. )
  19. :: DEFAULT - add any other params to %JENKINS_BUILD_ARGS%
  20. if [%1] NEQ [] (
  21. set JENKINS_BUILD_ARGS=%JENKINS_BUILD_ARGS% %1
  22. goto :ContinueArgParseEnd
  23. )
  24. :ContinueArgParseEnd
  25. shift
  26. goto :ContinueArgParse
  27. )
  28. :: ========================================
  29. :: Set up msbuild.exe
  30. :: ========================================
  31. call %REPO_ROOT%\Build\scripts\add_msbuild_path.cmd %JENKINS_FORCE_MSBUILD_VERSION%