diff options
author | Tyler Leonhardt <me@tylerleonhardt.com> | 2022-04-14 00:54:28 +0300 |
---|---|---|
committer | Tyler Leonhardt <me@tylerleonhardt.com> | 2022-04-14 00:54:28 +0300 |
commit | a6fc7a58de3a04f10eb11a5bc88ce8e932cd7951 (patch) | |
tree | 7b00037fce0adf78b4b8b526743283d3cf21ec46 /build/azure-pipelines | |
parent | bb5c5cba0b33f10c191bdddca18ce25e41c87f36 (diff) |
sort by length first and then name.
Diffstat (limited to 'build/azure-pipelines')
-rw-r--r-- | build/azure-pipelines/product-publish.ps1 | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/build/azure-pipelines/product-publish.ps1 b/build/azure-pipelines/product-publish.ps1 index 17b02f6aff5..5abfed48dca 100644 --- a/build/azure-pipelines/product-publish.ps1 +++ b/build/azure-pipelines/product-publish.ps1 @@ -29,8 +29,8 @@ if (Test-Path $ARTIFACT_PROCESSED_WILDCARD_PATH) { # This means that the latest artifact_processed_*.txt file has all of the contents of the previous ones. # Note: The kusto-like syntax only works in PS7+ and only in scripts, not at the REPL. Get-ChildItem $ARTIFACT_PROCESSED_WILDCARD_PATH - | Sort-Object - | Select-Object -Last 1 + # Sort by file name length first and then Name to make sure we sort numerically. Ex. 12 comes after 9. + | Sort-Object { $_.Name.Length },Name -Bottom 1 | Get-Content | ForEach-Object { $set.Add($_) | Out-Null |