Skip to content

Commit 4670902

Browse files
Remove learn.microsoft.com links from README section headers
Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent dd37987 commit 4670902

2,714 files changed

Lines changed: 398476 additions & 6431 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

AwakeCoding.OpenSpecs/Public/Update-OpenSpecIndex.ps1

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ function Update-OpenSpecIndex {
1010

1111
[switch]$IncludeDescription = $false,
1212

13-
[string[]]$OverviewProtocolIds = @()
13+
[string[]]$OverviewProtocolIds = @(),
14+
15+
[string[]]$ReferenceProtocolIds = @('MS-DTYP', 'MS-ERREF', 'MS-LCID', 'MS-UCODEREF')
1416
)
1517

1618
if (-not (Test-Path -LiteralPath $Path)) {
@@ -120,6 +122,12 @@ function Update-OpenSpecIndex {
120122
if ($trimmed) { [void]$overviewIds.Add($trimmed) }
121123
}
122124

125+
$referenceIds = [System.Collections.Generic.HashSet[string]]::new([System.StringComparer]::OrdinalIgnoreCase)
126+
foreach ($id in $ReferenceProtocolIds) {
127+
$trimmed = $id.Trim()
128+
if ($trimmed) { [void]$referenceIds.Add($trimmed) }
129+
}
130+
123131
$overviewEntries = New-Object System.Collections.Generic.List[object]
124132
$technicalEntries = New-Object System.Collections.Generic.List[object]
125133
$referenceEntries = New-Object System.Collections.Generic.List[object]
@@ -129,6 +137,10 @@ function Update-OpenSpecIndex {
129137
[void]$overviewEntries.Add($entry)
130138
continue
131139
}
140+
if ($referenceIds.Contains($entry.Name)) {
141+
[void]$referenceEntries.Add($entry)
142+
continue
143+
}
132144

133145
$catalogEntry = $catalogMap[$entry.Name]
134146
$sourcePage = ''
@@ -150,9 +162,6 @@ function Update-OpenSpecIndex {
150162
$sb = New-Object System.Text.StringBuilder
151163
[void]$sb.AppendLine("# $Title")
152164
[void]$sb.AppendLine()
153-
$totalCount = $entries.Count
154-
[void]$sb.AppendLine("$totalCount documents converted to Markdown.")
155-
[void]$sb.AppendLine()
156165

157166
$writeTable = {
158167
param($list, $includeDesc)
@@ -174,19 +183,16 @@ function Update-OpenSpecIndex {
174183
}
175184

176185
[void]$sb.AppendLine('## Overview Documents')
177-
[void]$sb.AppendLine("[Overview Documents]($overviewDocsUri)")
178186
[void]$sb.AppendLine()
179187
& $writeTable $overviewEntries $IncludeDescription
180188
[void]$sb.AppendLine()
181189

182190
[void]$sb.AppendLine('## Technical Documents')
183-
[void]$sb.AppendLine("[Technical Documents]($technicalDocsUri)")
184191
[void]$sb.AppendLine()
185192
& $writeTable $technicalEntries $IncludeDescription
186193
[void]$sb.AppendLine()
187194

188195
[void]$sb.AppendLine('## Reference Documents')
189-
[void]$sb.AppendLine("[Reference Documents]($referenceDocsUri)")
190196
[void]$sb.AppendLine()
191197
& $writeTable $referenceEntries $IncludeDescription
192198

18.8 KB
4.25 KB
5.03 KB
45.4 KB
7.55 KB
13.8 KB
6.11 KB
1.28 KB
3.41 KB

0 commit comments

Comments
 (0)