Skip to content

Commit

Permalink
remove useless ForEach-Object { [PSCustomObject] }
Browse files Browse the repository at this point in the history
  • Loading branch information
scbedd authored and azure-sdk committed Oct 30, 2024
1 parent fc5cf16 commit f5a1162
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions eng/common/scripts/job-matrix/Create-PrJobMatrix.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,11 @@ if (!(Test-Path $PRMatrixFile)) {

Write-Host "Generating PR job matrix for $PackagePropertiesFolder"

$configs = Get-Content -Raw $PRMatrixFile | ConvertFrom-Json | ForEach-Object { [PSCustomObject]$_ }
$configs = Get-Content -Raw $PRMatrixFile | ConvertFrom-Json

# calculate general targeting information and create our batches prior to generating any matrix
$packageProperties = Get-ChildItem -Recurse "$PackagePropertiesFolder" *.json `
| ForEach-Object { Get-Content -Path $_.FullName | ConvertFrom-Json } `
| ForEach-Object { [PSCustomObject]$_ }
| ForEach-Object { Get-Content -Path $_.FullName | ConvertFrom-Json }

# set default matrix config for each package if there isn't an override
$packageProperties | ForEach-Object {
Expand Down

0 comments on commit f5a1162

Please sign in to comment.