File tree Expand file tree Collapse file tree 1 file changed +18
-1
lines changed
Expand file tree Collapse file tree 1 file changed +18
-1
lines changed Original file line number Diff line number Diff line change 1111 [string ]$FilteredModules
1212)
1313
14+ $ResourceManagerFolders = Get-ChildItem - Path " .\src\ResourceManager"
1415Import-Module " $PSScriptRoot \HelpGeneration\HelpGeneration.psm1"
1516$UnfilteredHelpFolders = Get-ChildItem " help" - Recurse - Directory | where { $_.FullName -like " *$BuildConfig *" -and $_.FullName -notlike " *Stack*" }
1617$FilteredHelpFolders = $UnfilteredHelpFolders
@@ -36,6 +37,22 @@ if ($ValidateMarkdownHelp)
3637 New-Item - Path " $PSScriptRoot \..\src\Package" - Name " Exceptions" - ItemType Directory
3738 }
3839
40+ $Exceptions = @ ()
41+ foreach ($ServiceFolder in $ResourceManagerFolders )
42+ {
43+ $HelpFolder = Get-ChildItem - Path $ServiceFolder - Filter " help" - Recurse - Directory
44+ if ($HelpFolder -eq $null )
45+ {
46+ $Exceptions += $ServiceFolder.Name
47+ }
48+ }
49+
50+ if ($Exceptions.Count -gt 0 )
51+ {
52+ $Services = $Exceptions -Join " , "
53+ throw " No help folder found in the following services: $Services "
54+ }
55+
3956 $SuppressedExceptionsPath = " $PSScriptRoot \..\src\Package\Exceptions"
4057 $NewExceptionsPath = " $PSScriptRoot \..\src\Package"
4158 Copy-Item - Path " $PSScriptRoot \HelpGeneration\Exceptions\ValidateHelpIssues.csv" - Destination $SuppressedExceptionsPath
@@ -50,7 +67,7 @@ if ($ValidateMarkdownHelp)
5067 }
5168 else
5269 {
53- Remove-Item - Path " $NewExceptionsPath \ValidateHelpIssues.csv" - Force
70+ Remove-Item - Path " $NewExceptionsPath \ValidateHelpIssues.csv" - Force
5471 }
5572}
5673
You can’t perform that action at this time.
0 commit comments