opentofu / opentofu.org

The OpenTofu Website
https://opentofu.org/
Apache License 2.0
43 stars 21 forks source link

Throw on broken links #325

Closed mehhhhhhhhhhhhhhh closed 1 month ago

mehhhhhhhhhhhhhhh commented 1 month ago

Fixes https://github.com/opentofu/opentofu.org/issues/85

Related to https://github.com/opentofu/opentofu/issues/1863 (potentially a fix for that, albeit ~may require rebuild of runner image(?)~ edit: didn't; website runner uses fresh clone every time)

Changes Docusaurus' config to throw instead of warning when it detects broken links, as all the broken links should now be fixed.

Note that fixing these links lets through new warnings about broken anchors --onBrokenAnchors remains set to warn.

Be aware also that many of the problematic links "fixed" here were actually correct, but affected by a Docusaurus bug mis-parsing links where they are split over multiple lines of Markdown.

Follows two other PRs:

Effectively also merges https://github.com/opentofu/opentofu.org/pull/86 (original attempt to switch to throw).

mehhhhhhhhhhhhhhh commented 1 month ago

Just testing the build locally...

mehhhhhhhhhhhhhhh commented 1 month ago

Yep build looks good, both as a delta and on a clean checkout. Should be good to go :) :crossed_fingers:.

cam72cam commented 1 month ago

Thanks @mehhhhhhhhhhhhhhh !