Skip to content

Commit 7e00d5c

Browse files
committed
docs(*): Fixing the order of versions in the dropDown
1 parent 16d6b2c commit 7e00d5c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

angularDocsPostDeploy.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ Write-Host "Check file exists: " ([System.IO.File]::Exists($filePath))
6161
Write-Host "Check dir exists:" ([System.IO.Directory]::Exists($angularDocsRootFolder));
6262

6363
if([System.IO.File]::Exists($filePath) -and [System.IO.Directory]::Exists($angularDocsRootFolder)) {
64-
$folders = Get-ChildItem -Path $angularDocsRootFolder -Directory -Exclude $tagFolder,"sass","typescript";
64+
$folders = Get-ChildItem -Path $angularDocsRootFolder -Directory -Exclude $tagFolder,"sass","typescript" -Name | Sort-Object @{Expression = {[double]($_.Substring(0, $_.LastIndexOf('.'))) }};
6565
$textToUpdate = "";
6666
foreach($item in $folders) {
6767
$textToUpdate += '"' + $item.Name + '"';
@@ -72,4 +72,4 @@ if([System.IO.File]::Exists($filePath) -and [System.IO.Directory]::Exists($angul
7272
$content = [System.IO.File]::ReadAllText($filePath);
7373
$newContent = $content -replace "\[.*\]", $textToUpdate;
7474
[System.IO.File]::WriteAllText($filePath,$newContent);
75-
}
75+
}

0 commit comments

Comments
 (0)