Skip to content

ci(docs): fail PRs on broken Mintlify internal links - #1405

Open
HaoChiBao wants to merge 1 commit into
supermemoryai:mainfrom
HaoChiBao:fix/docs-broken-links-ci
Open

ci(docs): fail PRs on broken Mintlify internal links#1405
HaoChiBao wants to merge 1 commit into
supermemoryai:mainfrom
HaoChiBao:fix/docs-broken-links-ci

Conversation

@HaoChiBao

@HaoChiBao HaoChiBao commented Aug 3, 2026

Copy link
Copy Markdown

Summary

  • Adds apps/docs script check-links (mintlify broken-links) as the local and CI entrypoint
  • Runs that check in the existing .github/workflows/ci.yml Quality Checks job after install
  • Asserts the no broken links found report because mintlify 4.2.x can exit 0 even when it prints broken links

Fixes #1365

Test plan

  • mintlify broken-links / bun run check-links on Linux against apps/docs reports success no broken links found
  • CI Quality Checks passes on this PR, including the docs link step
  • Temporarily introduce a bad internal href and confirm CI fails

Comment thread apps/docs/index.mdx

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why have you changed these links?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question. Those link changes were not random. The new check runs mintlify broken-links, which is what you suggested as a follow up in #1362. That tool fails on page links that start with /docs, because Mintlify already adds /docs when you click them. So if the href already has /docs, you can end up on /docs/docs and get a 404. That is the same thing #1341 fixed. Those link cleanups are already on main from #1407, so I rebased and took the doc file changes out of this PR. This PR is only the CI check now.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense. I haven't checked myself, but to be sure we can confirm all the links resolve properly by running the development server locally.

Comment thread .github/workflows/docs-links.yml Outdated

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not edit an existing workflow rather than create a new workflow file docs-links.yml?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Having a separate workflow file was unnecessary. I moved the check into the existing CI workflow so it reuses the same install steps, and I deleted docs-links.yml.

@HaoChiBao
HaoChiBao force-pushed the fix/docs-broken-links-ci branch from e017c93 to 2cb4a7b Compare August 4, 2026 02:55
Add apps/docs check-links (mintlify broken-links) and run it in the
existing CI workflow. Assert a clean report because mintlify 4.2.x can
exit 0 even when broken links are printed.

Fixes supermemoryai#1365
@HaoChiBao
HaoChiBao force-pushed the fix/docs-broken-links-ci branch from 2cb4a7b to e382532 Compare August 4, 2026 03:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add broken-link checking for docs to CI

2 participants