Skip to content

Commit

Permalink
[skip changelog] Disable internal anchor checks by link checker tool (#…
Browse files Browse the repository at this point in the history
…1692)

Validation of links to internal anchors was recently added to the markdown-link-check tool used to check for broken
links in this project's documentation.

Although a much needed feature, unfortunately it does not currently support anchors created by HTML anchor tags.

For example, this is valid and common Markdown:

[click here](#some-anchor)
<a name="some-anchor"></a>

but will fail the check:

ERROR: 1 dead links found!
[x] #some-anchor -> Status: 404

This type of link markup is used by the protoc-gen-doc tool that generates the gRPC interface documentation, which
causes a spurious failure of the link check.

The solution is to configure markdown-link-check to skip these links (which was the behavior anyway with versions 3.8.7
and older). That will be reverted whenever the tool is able to correctly validate internal anchor links.
  • Loading branch information
per1234 authored Mar 22, 2022
1 parent ae57066 commit f470f40
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .markdown-link-check.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"retryCount": 3,
"aliveStatusCodes": [200, 206],
"ignorePatterns": [
{
"pattern": "^#"
},
{
"pattern": "https?://localhost:\\d*/"
},
Expand Down

0 comments on commit f470f40

Please sign in to comment.