From 173a5f0774a4a0634769f87c564b63c3ea93bece Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Mon, 5 Feb 2024 10:47:36 +0200 Subject: [PATCH] Reduce checkout size of submodules --- native/winui/ANGLE.cake | 2 +- scripts/azure-templates-bootstrapper.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/native/winui/ANGLE.cake b/native/winui/ANGLE.cake index 88c33903e6..5fe7e4285d 100644 --- a/native/winui/ANGLE.cake +++ b/native/winui/ANGLE.cake @@ -19,7 +19,7 @@ void InitializeAngle(string branch, DirectoryPath ANGLE_PATH, DirectoryPath WINA continue; RunProcess("git", new ProcessSettings { - Arguments = $"submodule update --init --recursive {submodule}", + Arguments = $"submodule update --init --recursive --depth 1 --single-branch {submodule}", WorkingDirectory = ANGLE_PATH.FullPath, }); } diff --git a/scripts/azure-templates-bootstrapper.yml b/scripts/azure-templates-bootstrapper.yml index ab003209e0..8e43dce46a 100644 --- a/scripts/azure-templates-bootstrapper.yml +++ b/scripts/azure-templates-bootstrapper.yml @@ -338,7 +338,7 @@ jobs: inputs: artifactName: ${{ parameters.artifactName }} pathToPublish: 'output' - - ${{ if eq(variables['System.TeamProject'], 'devdiv') }}: + - ${{ if and(eq(variables['System.TeamProject'], 'devdiv'), ne(parameters.buildPipelineType, 'tests'), ne(variables['System.PullRequest.IsFork'], 'true'), or(and(eq(variables['Build.Reason'], 'Schedule'), or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'], 'refs/heads/release/'))), parameters.runCompliance)) }}: - task: ComponentGovernanceComponentDetection@0 displayName: Run component detection condition: always()