File tree Expand file tree Collapse file tree 3 files changed +10
-2
lines changed
PipelineSteps/BatchGeneration Expand file tree Collapse file tree 3 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ if ($env:RUN_TEST_ON_ALL_MODULES -eq "True") {
33
33
}
34
34
else {
35
35
Write-Host " Run test on generated folder changed modules"
36
- # Only generated filder change should trigger the test
36
+ # Only generated folder change should trigger the test
37
37
for ($i = 0 ; $i -lt $ChangedFiles.Count ; $i ++ ) {
38
38
if ($ChangedFiles [$i ] -match ' ^generated/([^/]+)/([^/]+\.autorest)/' ) {
39
39
$moduleName = $Matches [2 ]
@@ -63,6 +63,11 @@ foreach ($subModule in $changedSubModules) {
63
63
Write-Host " ##[endgroup]"
64
64
Write-Host
65
65
66
+ $changedModulesRecordFile = Join-Path $artifactsDir ' filteredChangedModules.txt'
67
+ $changedModules | Set-Content - Path $changedModulesRecordFile - Encoding UTF8
68
+ $changedSubModulesRecordFile = Join-Path $artifactsDir ' filteredChangedSubModules.txt'
69
+ $changedSubModules | Set-Content - Path $changedSubModulesRecordFile - Encoding UTF8
70
+
66
71
$groupedBuildModules = Group-Modules - Modules $changedModules - MaxParallelJobs $MaxParallelBuildJobs
67
72
Write-Matrix - GroupedModules $groupedBuildModules - VariableName ' buildTargets' - RepoRoot $RepoRoot
68
73
Original file line number Diff line number Diff line change @@ -45,3 +45,6 @@ if ($MatrixStr -and $MatrixStr.Length -gt 1) {
45
45
$MatrixStr = $MatrixStr.Substring (1 )
46
46
}
47
47
Write-Host " ##vso[task.setVariable variable=generationTargets;isOutput=true]{$MatrixStr }"
48
+
49
+ $V4ModulesRecordFile = Join-Path $artifactsDir ' preparedV4Modules.txt'
50
+ $modules | Set-Content - Path $V4ModulesRecordFile - Encoding UTF8
Original file line number Diff line number Diff line change @@ -196,7 +196,7 @@ stages:
196
196
targetType : inline
197
197
pwsh : true
198
198
script : |
199
- $base = git merge-base HEAD origin/main
199
+ $base = git merge-base HEAD + origin/main
200
200
$changedFiles = git diff --name-only $base HEAD
201
201
202
202
$sourceBranchName = "$(Build.SourceBranch)".Replace('refs/heads/', '')
You can’t perform that action at this time.
0 commit comments