Skip to content

Commit 321937f

Browse files
azure-sdksima-zhu
andauthored
Sync eng/common directory with azure-sdk-tools for PR 4480 (#26992)
* Add extra parameters for .net readme path * Use another way for default value * Remove custom source Co-authored-by: sima-zhu <[email protected]>
1 parent c4013f0 commit 321937f

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

eng/common/scripts/Update-DocsMsToc.ps1

+7-2
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,19 @@ depending on the requirements for the domain
2929
.PARAMETER OutputLocation
3030
Output location for unified reference yml file
3131
32+
.PARAMETER ReadmeFolderRoot
33+
The readme folder root path, use default value here for backward compability. E.g. docs-ref-services in Java, JS, Python, api/overview/azure
3234
#>
3335

3436
param(
3537
[Parameter(Mandatory = $true)]
3638
[string] $DocRepoLocation,
3739

3840
[Parameter(Mandatory = $true)]
39-
[string] $OutputLocation
41+
[string] $OutputLocation,
42+
43+
[Parameter(Mandatory = $false)]
44+
[string] $ReadmeFolderRoot = 'docs-ref-services'
4045
)
4146
. $PSScriptRoot/common.ps1
4247
. $PSScriptRoot/Helpers/PSModule-Helpers.ps1
@@ -208,7 +213,7 @@ foreach ($service in $serviceNameList) {
208213
$serviceReadmeBaseName = $service.ToLower().Replace(' ', '-').Replace('/', '-')
209214
$serviceTocEntry = [PSCustomObject]@{
210215
name = $service;
211-
href = "~/docs-ref-services/{moniker}/$serviceReadmeBaseName.md"
216+
href = "~/$ReadmeFolderRoot/{moniker}/$serviceReadmeBaseName.md"
212217
landingPageType = 'Service'
213218
items = @($packageItems)
214219
}

0 commit comments

Comments
 (0)