platyPS icon indicating copy to clipboard operation
platyPS copied to clipboard

Links in the ModulePage does not work when used -ModulePagePath in a different folder

Open ranabanerjee15 opened this issue 5 years ago • 4 comments

Steps to reproduce

$path = 'C:\Users\banerjeeR\Projects\O365MigrationOps' Set-Location $path Import-Module .\O365MigrationOps.psm1 -Force New-MarkdownHelp -Module O365MigrationOps -OutputFolder $path\docs -WithModulePage -ModulePagePath $path\Index.md New-ExternalHelp .\docs -OutputPath en-US\

Open index.md and click a link to any function

Expected behavior

It shall navigate to the Function.md

Actual behavior

Errors encountered, Error Details attached

Environment data

platyps Version 0.13.0 2019-03-15 19_42_13-SAPIEN PowerShell Studio 2019

v0.5.0

ranabanerjee15 avatar Mar 15 '19 09:03 ranabanerjee15

Can you share a snippet from index.md? From the first glance the problem is in VS code, but let's try to find out.

vors avatar Mar 16 '19 23:03 vors

I've got the same issue:

Steps to Reproduce

$ModuleName = TestModule
$OutputFolder = ".\Modules\$ModuleName\Docs"
$ModulePagePath = ".\Modules\$ModuleName\README.md"
New-MarkdownHelp -Module $ModuleName -OutputFolder $OutputFolder -WithModulePage -ModulePagePath $ModulePagePath -Force

Expected Behaviour

README.md

---
Module Name: TestModule
Module Guid: 00000000-0000-0000-0000-000000000000
Download Help Link: {{ Update Download Link }}
Help Version: {{ Please enter version of help manually (X.X.X.X) format }}
Locale: en-US
---
# TestModule Module
## Description
{{ Fill in the Description }}

## TestModule Cmdlets
### [Test-Function](Docs/Test-Function.md)
{{ Fill in the Description }}

Actual Behaviour

README.md

---
Module Name: TestModule
Module Guid: 00000000-0000-0000-0000-000000000000
Download Help Link: {{ Update Download Link }}
Help Version: {{ Please enter version of help manually (X.X.X.X) format }}
Locale: en-US
---
# TestModule Module
## Description
{{ Fill in the Description }}

## TestModule Cmdlets
### [Test-Function](Test-Function.md)
{{ Fill in the Description }}

When ModulePagePath is specified, the function needs to calculate the relative path difference between the OutputFolder and ModulePagePath and prefix the cmdlet links in the Module Page with this path.

X-Guardian avatar Apr 04 '19 10:04 X-Guardian

Ah I see

When ModulePagePath is specified, the function needs to calculate the relative path difference between the OutputFolder and ModulePagePath and prefix the cmdlet links in the Module Page with this path.

Thank you for the explanation!

vors avatar Jun 10 '19 05:06 vors

Thank you for reporting this issue. The current behavior is by design - it is expected to have the module page in the same location as the cmdlet reference. I do like the addition of this feature, so we will investigate after 2.0 GA.

theJasonHelmick avatar Aug 09 '21 17:08 theJasonHelmick

This is by design.

sdwheeler avatar May 31 '24 15:05 sdwheeler