Skip to content

Commit 99a0aa8

Browse files
azure-powershell-botazurepowershell
and
azurepowershell
authored
Sync tools folder from main branch to generation branch (#20666)
Co-authored-by: azurepowershell <azurepowershell@ms.com>
1 parent a031d5d commit 99a0aa8

File tree

9 files changed

+246
-240
lines changed

9 files changed

+246
-240
lines changed

tools/Az/Az.psd1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ DotNetFrameworkVersion = '4.7.2'
5252
# ProcessorArchitecture = ''
5353

5454
# Modules that must be imported into the global environment prior to importing this module
55-
RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.11.0'; },
55+
RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.11.1'; },
5656
@{ModuleName = 'Az.Advisor'; RequiredVersion = '2.0.0'; },
5757
@{ModuleName = 'Az.Aks'; RequiredVersion = '5.2.0'; },
5858
@{ModuleName = 'Az.AnalysisServices'; RequiredVersion = '1.1.4'; },

tools/AzPreview/AzPreview.psd1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ DotNetFrameworkVersion = '4.7.2'
5252
# ProcessorArchitecture = ''
5353

5454
# Modules that must be imported into the global environment prior to importing this module
55-
RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.11.0'; },
55+
RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.11.1'; },
5656
@{ModuleName = 'Az.ADDomainServices'; RequiredVersion = '0.2.0'; },
5757
@{ModuleName = 'Az.Advisor'; RequiredVersion = '2.0.0'; },
5858
@{ModuleName = 'Az.Aks'; RequiredVersion = '5.2.0'; },

tools/CheckAssemblies.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function Get-PreloadAssemblies{
2727
Write-Host "Getting preload assemblies in $BuildFolder for $ModuleFolder"
2828
Add-Type -Path ([System.IO.Path]::Combine($BuildFolder, "Az.Accounts", "Microsoft.Azure.PowerShell.AssemblyLoading.dll"))
2929
$assemblyRootPath = [System.IO.Path]::Combine($BuildFolder, "Az.Accounts", "lib")
30-
$conditionalAssemblyContext = [Microsoft.Azure.PowerShell.AssemblyLoading.ConditionalAssemblyContext]::new($Host.Version)
30+
$conditionalAssemblyContext = [Microsoft.Azure.PowerShell.AssemblyLoading.ConditionalAssemblyContext]::new($PSVersionTable.PSEdition, $PSVersionTable.PSVersion)
3131
[Microsoft.Azure.PowerShell.AssemblyLoading.ConditionalAssemblyProvider]::Initialize($assemblyRootPath, $conditionalAssemblyContext)
3232
$assemblyDict = [Microsoft.Azure.PowerShell.AssemblyLoading.ConditionalAssemblyProvider]::GetAssemblies()
3333
return $assemblyDict.Keys

tools/Docs/az-ps-latest.csv

Lines changed: 132 additions & 132 deletions
Large diffs are not rendered by default.

tools/ExecuteCIStep.ps1

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,11 +189,12 @@ If ($Build)
189189
{
190190
$ModuleInfoList += @{
191191
Module = "Az.$ModuleName";
192-
Status = $DependencyStepStatus;
192+
Status = "Running";
193193
Content = "";
194194
}
195195
}
196196
$Detail = @{
197+
Platform = $Platform;
197198
Modules = $ModuleInfoList;
198199
}
199200
$Template.$DependencyStep.Details += $Detail

tools/Gen2Master/MoveFromGeneration2Master.ps1

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,12 @@ Function Move-Generation2MasterHybrid {
299299
dotnet sln $SolutionPath add (Join-Path -Path (Join-Path -Path $DestPath -ChildPath $submoduleDir.Name) -ChildPath Az.$submoduleName.csproj)
300300

301301
# Update psd1
302-
$DestPsd1Path = Join-Path -Path (Join-Path -Path $DestPath -ChildPath $ModuleName) -ChildPath "Az.$ModuleName.psd1"
303-
$Psd1Metadata = Import-LocalizedData -BaseDirectory (Join-Path -Path $DestPath -ChildPath $ModuleName) -FileName "Az.$ModuleName.psd1"
302+
$Psd1FolderPostfix = '';
303+
if (-not (Test-Path (Join-Path -Path (Join-Path -Path $DestPath -ChildPath $ModuleName) -ChildPath "Az.$ModuleName.psd1"))) {
304+
$Psd1FolderPostfix = '.Management'
305+
}
306+
$DestPsd1Path = Join-Path -Path (Join-Path -Path $DestPath -ChildPath $ModuleName$Psd1FolderPostfix) -ChildPath "Az.$ModuleName.psd1"
307+
$Psd1Metadata = Import-LocalizedData -BaseDirectory (Join-Path -Path $DestPath -ChildPath $ModuleName$Psd1FolderPostfix) -FileName "Az.$ModuleName.psd1"
304308
$SubModulePsd1MetaData = Import-LocalizedData -BaseDirectory (Join-Path -Path $SourcePath -ChildPath $submoduleDir.Name) -FileName "Az.$submoduleName.psd1"
305309
if (!@($Psd1Metadata.RequiredAssemblies).Contains(("{0}\bin\Az.${submoduleName}.private.dll" -f $submoduleDir.Name))) {
306310
$Psd1Metadata.RequiredAssemblies = @($Psd1Metadata.RequiredAssemblies) + ("{0}\bin\Az.${submoduleName}.private.dll" -f $submoduleDir.Name)
@@ -339,11 +343,12 @@ Function Move-Generation2MasterHybrid {
339343
$job = start-job {
340344
param(
341345
[string] $ModuleName,
342-
[string] $DestPath
346+
[string] $DestPath,
347+
[string] $Psd1FolderPostfix
343348
)
344349
Import-Module "$DestPath\..\..\artifacts\Debug\Az.$ModuleName\Az.$ModuleName.psd1"
345-
Update-MarkdownHelpModule -Path "$DestPath\$ModuleName\help" -RefreshModulePage -AlphabeticParamsOrder -UseFullTypeName -ExcludeDontShow
346-
} -ArgumentList $ModuleName, $DestPath
350+
Update-MarkdownHelpModule -Path "$DestPath\$ModuleName$Psd1FolderPostfix\help" -RefreshModulePage -AlphabeticParamsOrder -UseFullTypeName -ExcludeDontShow
351+
} -ArgumentList $ModuleName, $DestPath, $Psd1FolderPostfix
347352

348353
$job | Wait-Job | Receive-Job
349354
# Import-Module "$DestPath\..\..\artifacts\Debug\Az.$ModuleName\Az.$ModuleName.psd1"

tools/PipelineResultTemplate.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,42 @@
11
{
22
"build": {
3-
"Name": "Build",
3+
"PhaseName": "Build",
44
"Order": 1,
55
"Details": [
66
]
77
},
88
"breaking-change": {
9-
"Name": "Breaking Change Check",
9+
"PhaseName": "Breaking Change Check",
1010
"Order": 2,
1111
"Details": [
1212
]
1313
},
1414
"signature": {
15-
"Name": "Signature Check",
15+
"PhaseName": "Signature Check",
1616
"Order": 3,
1717
"Details": [
1818
]
1919
},
2020
"help-example": {
21-
"Name": "Help Example Check",
21+
"PhaseName": "Help Example Check",
2222
"Order": 4,
2323
"Details": [
2424
]
2525
},
2626
"help": {
27-
"Name": "Help File Existence Check",
27+
"PhaseName": "Help File Existence Check",
2828
"Order": 5,
2929
"Details": [
3030
]
3131
},
3232
"file-change": {
33-
"Name": "File Change Check",
33+
"PhaseName": "File Change Check",
3434
"Order": 6,
3535
"Details": [
3636
]
3737
},
3838
"test": {
39-
"Name": "Test",
39+
"PhaseName": "Test",
4040
"Order": 100,
4141
"Details": [
4242
]

tools/StaticAnalysis/CollectStaticAnalysisPipelineResult.ps1

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -51,32 +51,32 @@ ForEach ($Step In $DependencyStepList)
5151

5252
$Steps = @(
5353
@{
54-
StepName = "breaking-change"
54+
PhaseName = "breaking-change"
5555
IssuePath = "$StaticAnalysisOutputDirectory/BreakingChangeIssues.csv"
5656
},
5757
@{
58-
StepName = "help"
58+
PhaseName = "help"
5959
IssuePath = "$StaticAnalysisOutputDirectory/HelpIssues.csv"
6060
},
6161
@{
62-
StepName = "help-example"
62+
PhaseName = "help-example"
6363
IssuePath = "$StaticAnalysisOutputDirectory/ExampleIssues.csv"
6464
},
6565
@{
66-
StepName = "signature"
66+
PhaseName = "signature"
6767
IssuePath = "$StaticAnalysisOutputDirectory/SignatureIssues.csv"
6868
},
6969
@{
70-
StepName = "file-change"
70+
PhaseName = "file-change"
7171
IssuePath = "$StaticAnalysisOutputDirectory/FileChangeIssue.csv"
7272
}
7373
)
7474

7575
ForEach ($Step In $Steps)
7676
{
77-
$StepName = $Step.StepName
77+
$PhaseName = $Step.PhaseName
7878
$IssuePath = $Step.IssuePath
79-
$Details = $Template.$StepName.Details
79+
$Details = $Template.$PhaseName.Details
8080
If ($Details.Length -Ne 0)
8181
{
8282
$Details = $Details[0]
@@ -115,11 +115,11 @@ ForEach ($Step In $Steps)
115115
{
116116
#Region generate table head of each step
117117
$NormalSteps = [System.Collections.Generic.HashSet[String]]@("breaking-change", "help", "signature", "file-change")
118-
If ($NormalSteps.Contains($StepName))
118+
If ($NormalSteps.Contains($PhaseName))
119119
{
120120
$Content = "|Type|Cmdlet|Description|Remediation|`n|---|---|---|---|`n"
121121
}
122-
ElseIf ($StepName -Eq "help-example")
122+
ElseIf ($PhaseName -Eq "help-example")
123123
{
124124
$Content = "|Type|Cmdlet|Example|Line|RuleName|Description|Extent|Remediation|`n|---|---|---|---|---|---|---|---|`n"
125125
}
@@ -136,11 +136,11 @@ ForEach ($Step In $Steps)
136136
$ErrorTypeEmoji = "⚠️"
137137
}
138138
#Region generate table content of each step
139-
If ($NormalSteps.Contains($StepName))
139+
If ($NormalSteps.Contains($PhaseName))
140140
{
141141
$Content += "|$ErrorTypeEmoji|$($Issue.Target)|$($Issue.Description)|$($Issue.Remediation)|`n"
142142
}
143-
ElseIf ($StepName -Eq "help-example")
143+
ElseIf ($PhaseName -Eq "help-example")
144144
{
145145
$Content += "|$ErrorTypeEmoji|$($Issue.Target)|$($Issue.Example)|$($Issue.Line)|$($Issue.RuleName)|$($Issue.Description)|$($Issue.Extent)|$($Issue.Remediation)|`n"
146146
}

0 commit comments

Comments
 (0)