Skip to content

Commit

Permalink
Merge pull request #1 from sandyarmstrong/anchors-away
Browse files Browse the repository at this point in the history
Support in-page header links
  • Loading branch information
cmbrose authored May 5, 2021
2 parents c7b8464 + ddf59da commit 11bb98c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions action.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,13 @@ Function UpdateFileLinks()
Write-Verbose "Link $link is already absolute, nothing to do"
return "[$text]($link)"
}

if ($link -like "#*")
{
# Header anchor, no change
Write-Verbose "Link $link is to an anchor within the page (generally a header), nothing to do"
return "[$text]($link)"
}

$upDirs = 0
$path = @()
Expand Down

0 comments on commit 11bb98c

Please sign in to comment.