Skip to content

Commit 4395866

Browse files
azure-sdksima-zhu
andauthored
Add package source override to toc script. (Azure#32231)
Co-authored-by: sima-zhu <[email protected]>
1 parent 4ee13d7 commit 4395866

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

eng/common/scripts/Update-DocsMsToc.ps1

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@ Output location for unified reference yml file
3131
3232
.PARAMETER ReadmeFolderRoot
3333
The readme folder root path, use default value here for backward compability. E.g. docs-ref-services in Java, JS, Python, api/overview/azure
34+
35+
.PARAMETER PackageSourceOverride
36+
Optional parameter to supply a different package source (useful for daily dev
37+
docs generation from pacakges which are not published to the default feed). This
38+
variable is meant to be used in the domain-specific business logic in
39+
&$GetDocsMsTocDataFn
3440
#>
3541

3642
param(
@@ -41,7 +47,10 @@ param(
4147
[string] $OutputLocation,
4248

4349
[Parameter(Mandatory = $false)]
44-
[string] $ReadmeFolderRoot = 'docs-ref-services'
50+
[string] $ReadmeFolderRoot = 'docs-ref-services',
51+
52+
[Parameter(Mandatory = $false)]
53+
[string] $PackageSourceOverride
4554
)
4655
. $PSScriptRoot/common.ps1
4756
. $PSScriptRoot/Helpers/PSModule-Helpers.ps1
@@ -53,7 +62,8 @@ Set-StrictMode -Version 3
5362
function GetPackageNode($package) {
5463
$packageInfo = &$GetDocsMsTocDataFn `
5564
-packageMetadata $package `
56-
-docRepoLocation $DocRepoLocation
65+
-docRepoLocation $DocRepoLocation `
66+
-PackageSourceOverride $PackageSourceOverride
5767

5868
return [PSCustomObject]@{
5969
name = $packageInfo.PackageTocHeader

0 commit comments

Comments
 (0)