diff --git a/.azure-pipelines/code-gen.yml b/.azure-pipelines/code-gen.yml index e29ae3ad5daf..fdc50644c1a9 100644 --- a/.azure-pipelines/code-gen.yml +++ b/.azure-pipelines/code-gen.yml @@ -75,21 +75,25 @@ jobs: } git checkout src/${{ parameters.ServiceName }}; git checkout -b codegen/${{ parameters.ServiceName }} origin/${{ parameters.TargetBranch }}; - - pwsh: | - #Uninstall-Module -Name PackageManagement -AllVersions - Install-Module -Name PowerShellGet -RequiredVersion 2.2.3 -Force; - Install-Module -Name platyPS -RequiredVersion 0.14.2 -Force; - Install-Module -Name Az.Accounts -Force; - Import-Module .\tools\Gen2Master\MoveFromGeneration2Master.ps1; - Move-Generation2Master -SourcePath .\artifacts\src\${{ parameters.ServiceName }} -DestPath .\src\${{ parameters.ServiceName }}; - git config user.email "65331932+azure-powershell-bot@users.noreply.github.com"; - git config user.name "azure-powershell-bot"; - git add ./src; - git add tools/CreateMappings_rules.json; - git commit -m "Move ${{ parameters.ServiceName }} to ${{ parameters.TargetBranch }}"; - git remote set-url origin https://azure-powershell-bot:$(GithubToken)@github.com/Azure/azure-powershell.git; - git push origin codegen/${{ parameters.ServiceName }} --force; - displayName: Create codegen/${{ parameters.ServiceName }} branch + - task: PowerShell@2 + displayName: 'Create codegen/${{ parameters.ServiceName }} branch' + inputs: + targetType: 'inline' + script: | + #Uninstall-Module -Name PackageManagement -AllVersions; + Install-Module -Name PowerShellGet -RequiredVersion 2.2.3 -Force; + Install-Module -Name platyPS -RequiredVersion 0.14.2 -Force; + Install-Module -Name Az.Accounts -Force; + Import-Module .\tools\Gen2Master\MoveFromGeneration2Master.ps1; + Move-Generation2Master -SourcePath .\artifacts\src\${{ parameters.ServiceName }} -DestPath .\src\${{ parameters.ServiceName }}; + git config user.email "65331932+azure-powershell-bot@users.noreply.github.com"; + git config user.name "azure-powershell-bot"; + git add src; + git add tools/CreateMappings_rules.json; + git commit -m "Move ${{ parameters.ServiceName }} to ${{ parameters.TargetBranch }}"; + git remote set-url origin https://azure-powershell-bot:$(GithubToken)@github.com/Azure/azure-powershell.git; + git push origin codegen/${{ parameters.ServiceName }} --force; + arguments: '-RequiredPsVersion $(PSVersion)' - pwsh: | $SourceBranch = "$(Build.SourceBranch)" $SourceBranch = $SourceBranch.Replace("refs/heads/", "") @@ -101,4 +105,4 @@ jobs: $(git log -1 origin/$SourceBranch -- ./src/${{ parameters.ServiceName }}) " ./tools/Github/CreatePR.ps1 -Title $Title -HeadBranch $HeadBranch -BaseBranch $BaseBranch -BotAccessToken $(GithubToken) -Description $Description - displayName: Create PR to main branch \ No newline at end of file + displayName: Create PR to main branch diff --git a/.azure-pipelines/code-sign.yml b/.azure-pipelines/code-sign.yml index 87115c59a9c4..b27fc1cf0b33 100644 --- a/.azure-pipelines/code-sign.yml +++ b/.azure-pipelines/code-sign.yml @@ -301,7 +301,7 @@ jobs: inputs: command: custom custom: msbuild - arguments: 'build.proj /t:Publish /p:Configuration=Release;NuGetKey=$(NuGetKey);GenerateDocumentationFile=false' + arguments: 'build.proj /t:Publish /p:Configuration=Release;NuGetKey=$(NuGetKey);GenerateDocumentationFile=false;TargetModule=${{ parameters.TargetModule }}' - pwsh: | #this task won't be triggered unless $AzureStack was set to true diff --git a/.github/policies/resourceManagement.yml b/.github/policies/resourceManagement.yml index 85624a3d2a86..5fb207a18f84 100644 --- a/.github/policies/resourceManagement.yml +++ b/.github/policies/resourceManagement.yml @@ -430,6 +430,22 @@ configuration: - Azure/deployments-owners replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False + - if: + - or: + - labelAdded: + label: Service Attention + - labelAdded: + label: arm-bicep + - hasLabel: + label: Service Attention + - hasLabel: + label: arm-bicep + then: + - mentionUsers: + mentionees: + - Azure/deployments-owners + replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. + assignMentionees: False - if: - or: - labelAdded: @@ -692,6 +708,22 @@ configuration: - maertendMSFT replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False + - if: + - or: + - labelAdded: + label: Service Attention + - labelAdded: + label: CloudService + - hasLabel: + label: Service Attention + - hasLabel: + label: CloudService + then: + - mentionUsers: + mentionees: + - bberera + replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. + assignMentionees: False - if: - or: - labelAdded: @@ -2031,7 +2063,7 @@ configuration: then: - mentionUsers: mentionees: - - Elsie4ever + - Elsie4ever,MohinderAtwal replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False - if: @@ -2197,7 +2229,7 @@ configuration: then: - mentionUsers: mentionees: - - varunkch (Azure Cli route to zhoxing-ms) + - RamyaElangovanP replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False - if: @@ -3327,7 +3359,7 @@ configuration: then: - mentionUsers: mentionees: - - chiragg4u + - venu-l replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False - if: @@ -3628,6 +3660,22 @@ configuration: - azureSQLGitHub replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False + - if: + - or: + - labelAdded: + label: Service Attention + - labelAdded: + label: StackHCIVM + - hasLabel: + label: Service Attention + - hasLabel: + label: StackHCIVM + then: + - mentionUsers: + mentionees: + - arc-enabled-vms-on-hci Team + replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. + assignMentionees: False - if: - or: - labelAdded: diff --git a/build.proj b/build.proj index 2e19f0d135a2..aee57b037547 100644 --- a/build.proj +++ b/build.proj @@ -44,8 +44,8 @@ false false - true - false + true + false diff --git a/tools/AzPreview/AzPreview.psd1 b/tools/AzPreview/AzPreview.psd1 index 9d3669a457ce..010244ea572b 100644 --- a/tools/AzPreview/AzPreview.psd1 +++ b/tools/AzPreview/AzPreview.psd1 @@ -76,6 +76,7 @@ RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.15.1'; }, @{ModuleName = 'Az.Cdn'; RequiredVersion = '3.1.1'; }, @{ModuleName = 'Az.ChangeAnalysis'; RequiredVersion = '0.1.0'; }, @{ModuleName = 'Az.CloudService'; RequiredVersion = '2.0.0'; }, + @{ModuleName = 'Az.CodeSigning'; RequiredVersion = '0.1.0'; }, @{ModuleName = 'Az.CognitiveServices'; RequiredVersion = '1.14.1'; }, @{ModuleName = 'Az.Communication'; RequiredVersion = '0.2.0'; }, @{ModuleName = 'Az.Compute'; RequiredVersion = '7.1.1'; }, diff --git a/tools/CreateMappings_rules.json b/tools/CreateMappings_rules.json index de58479cbe9c..10c553b1ef60 100644 --- a/tools/CreateMappings_rules.json +++ b/tools/CreateMappings_rules.json @@ -863,5 +863,9 @@ { "module": "ManagedNetworkFabric", "alias": "Managed Network Fabric" + }, + { + "module": "CodeSigning", + "alias": "Code Signing" } ] diff --git a/tools/Gen2Master/MoveFromGeneration2Master.ps1 b/tools/Gen2Master/MoveFromGeneration2Master.ps1 index 6fa66f1174f7..d99919817ca2 100644 --- a/tools/Gen2Master/MoveFromGeneration2Master.ps1 +++ b/tools/Gen2Master/MoveFromGeneration2Master.ps1 @@ -24,7 +24,12 @@ Function Move-Generation2Master { process { #Region Handle the module whoes folder is a subfolder of the module folder. - $ModuleName = $SourcePath.Replace('/', '\').Split('\src\')[1].Split('\')[0] + if (-not (Test-Path -Path $SourcePath)) { + Write-Error "The source path $SourcePath does not exist." -ForegroundColor Red + return + } + $SourceFolder = Get-Item -Path $SourcePath + $ModuleName = $SourceFolder.Name $DestParentPath = $DestPath While ("" -ne $DestParentPath) { @@ -43,6 +48,7 @@ Function Move-Generation2Master { New-Item "$DestPath\$ModuleName\help" -ItemType Directory Update-MappingJson $ModuleName } + $DestPath = (Get-Item -Path $DestPath).FullName $Dir2Copy = @{ 'custom' = 'custom' 'examples' = 'examples' @@ -68,7 +74,7 @@ Function Move-Generation2Master { $Psd1Metadata = Import-LocalizedData -BaseDirectory "$PSScriptRoot/Templates" -FileName "Module.psd1" } foreach ($submoduleDir in $submoduleDirs) { - $psd1File = Get-ChildItem -Filter *.psd1 -File -Path $submoduleDir + $psd1File = Get-ChildItem -Filter *.psd1 -File -Path $submoduleDir.FullName write-host ("psd1 file name {0}" -f $psd1File.Name) $submoduleName = $psd1File.Name.Split('.')[-2] Foreach ($Dir in $Dir2Copy.GetEnumerator()) {