From 47e9a1d1c1f95f26020ccf44c4bef570ac740583 Mon Sep 17 00:00:00 2001 From: Markus Rickert Date: Mon, 18 May 2020 20:05:23 +0200 Subject: [PATCH] [vcpkg] msbuild: do not build vcpkgmetricsuploader when -disableMetrics (#11368) --- scripts/bootstrap.ps1 | 7 ++++++- toolsrc/dirs.proj | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/scripts/bootstrap.ps1 b/scripts/bootstrap.ps1 index 1eaf1c59833..8603647b31c 100644 --- a/scripts/bootstrap.ps1 +++ b/scripts/bootstrap.ps1 @@ -426,5 +426,10 @@ Read more about vcpkg telemetry at docs/about/privacy.md Write-Verbose "Placing vcpkg.exe in the correct location" Copy-Item "$vcpkgReleaseDir\vcpkg.exe" "$vcpkgRootDir\vcpkg.exe" -Copy-Item "$vcpkgReleaseDir\vcpkgmetricsuploader.exe" "$vcpkgRootDir\scripts\vcpkgmetricsuploader.exe" + +if (-not $disableMetrics) +{ + Copy-Item "$vcpkgReleaseDir\vcpkgmetricsuploader.exe" "$vcpkgRootDir\scripts\vcpkgmetricsuploader.exe" +} + Remove-Item "$vcpkgReleaseDir" -Force -Recurse -ErrorAction SilentlyContinue diff --git a/toolsrc/dirs.proj b/toolsrc/dirs.proj index 7729c989792..960374bffd1 100644 --- a/toolsrc/dirs.proj +++ b/toolsrc/dirs.proj @@ -5,7 +5,7 @@ - +