Skip to content

Q: Who should create the Folder $ReadTheDocsPath = Join-Path $BuildDocsPath 'ReadTheDocs'? #9

Description

@schittli

Good morning

If I .\Build.ps1 a simple Testproject, then I get the Exception, that the Folder C:\Temp\--\-PSModul\jig\build\docs\ReadTheDocs is missing:

Task /./CreateHelp/CreateProjectHelp/UpdateReadTheDocs                                                                
* Copy ReadTheDocs markdown files to project root document folder                                                     
ERROR: Cannot find path 'C:\Temp\--\-PSModul\jig\build\docs\ReadTheDocs' because it does not exist.                   
At C:\Temp\--\-PSModul\jig\jig.build.ps1:659 char:19                                                                  
+ ... $RTDFolders = Get-ChildItem -Path $ReadTheDocsPath -Directory | Sort- ...                                       
+                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~                                                   

If I review task UpdateReadTheDocs, then it except that the Directory $ReadTheDocsPath must already exist:

# Synopsis: Update ReadTheDocs project documentation
task UpdateReadTheDocs -if {$Script:BuildEnv.OptionGenerateReadTheDocs} {
    Write-Description White 'Copy ReadTheDocs markdown files to project root document folder' -accent

    $BuildDocsPath = Join-Path $BuildRoot "$($Script:BuildEnv.BuildToolFolder)\docs\"
    $ProjectDocsPath = Join-Path $BuildRoot 'docs'
    $ReadTheDocsPath = Join-Path $BuildDocsPath 'ReadTheDocs'
    $DocsReleasePath = Join-Path $Script:BuildEnv.BaseReleaseFolder $Script:BuildEnv.ModuleToBuild

    $RTDFolders = Get-ChildItem -Path $ReadTheDocsPath -Directory | Sort-Object -Property Name
    (…)
}

Therefore my question: who should create this path: Join-Path $BuildDocsPath 'ReadTheDocs'?

I guess, it should be either the Initialize-ModuleBuild or the "Docs creation task".

Thanks a lot for your help, kind regards, Tom

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions