File tree Expand file tree Collapse file tree
AzureDevOpsPowerShell/Public/Api/DistributedTask/VariableGroups Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -97,12 +97,18 @@ function New-AzDoVariableGroup {
9797 if ($PSCmdlet.ShouldProcess ($ProjectName , " Create Variable Group named: $ ( $PSStyle.Bold ) $name $ ( $PSStyle.Reset ) " )) {
9898 try {
9999 ($body | Invoke-AzDoRestMethod @params ) | ForEach-Object {
100+ $variablesObject = $_.variables | ConvertTo-Json - Depth 10 | ConvertFrom-Json - AsHashtable - Depth 10
101+
102+ $variablesOutput = @ {}
103+ foreach ($item in $variablesObject.GetEnumerator ()) {
104+ $variablesOutput [$item.Key ] = $item.value.value
105+ }
100106 [PSCustomObject ]@ {
101107 CollectionURI = $CollectionUri
102108 ProjectName = $ProjectName
103109 VariableGroupName = $_.name
104110 VariableGroupId = $_.id
105- Variables = $_ .variables
111+ Variables = $variablesOutput
106112 CreatedOn = $_.createdOn
107113 IsShared = $_.isShared
108114 }
You can’t perform that action at this time.
0 commit comments