Skip to content

docs: fix doc references that never resolved, and gate cargo doc in CI - #3834

Merged
KuSh merged 1 commit into
rtk-ai:developfrom
KuSh:docs/fix-relative-links
Oct 8, 2026
Merged

KuSh merged 1 commit into
rtk-ai:developfrom
KuSh:docs/fix-relative-links

Conversation

@KuSh

@KuSh KuSh commented Sep 2, 2026 •

Copy link
Copy Markdown
Collaborator

What

Fixes documentation references that never resolved, and adds the CI gate that keeps the rustdoc half from coming back.

Markdown. 42 relative links and anchors on develop point nowhere. docs/TROUBLESHOOTING.md moved to docs/guide/resources/troubleshooting.md and six files still use the old path. docs/contributing/TECHNICAL.md addresses the repo root as ../, which lands in docs/, so its 29 links to src/ and hooks/ READMEs have never worked. SECURITY.md names a workflow whose jobs now live in ci.yml, the two docs/usage/ pages point at files one level too high, and CONTRIBUTING.md links TECHNICAL.md#testing where the heading is ## 8. Testing.

.github/PULL_REQUEST_TEMPLATE.md keeps its ../blob/master/CONTRIBUTING.md form on purpose. GitHub renders that file into the PR body, so the link resolves against the PR URL: that form reaches the file and ../CONTRIBUTING.md returns 404. A comment above the link says so, because the form reads like a mistake.

rustdoc. cargo doc fails on develop: warnings = "deny" makes rustdoc lints fatal, and 20 doc comments trip one. Most are literal output tokens rustdoc reads as markup, such as sbt's [info] lines, argv[0] and <ref>; three are bare URLs. Two in user_env.rs link to #[cfg(test)] helpers rustdoc cannot see, and one in tracking.rs names a track function that no longer exists.

src/main.rs silences the lint with an allow instead of backticks, because that doc comment is clap's help text and backticks would show up in rtk git --help.

CI. Nothing runs cargo doc today; the doc review job is the AI reviewer. A rustdoc job now runs beside fmt and clippy.

Rules. Rule 6 of .claude/rules/rust-patterns.md sends contributors to tokenize_with_options, which does not exist; it now names tokenize_grammar.

No change to command output or behaviour.

Test plan

  • cargo doc --no-deps: 20 errors on develop e0b2e85, 0 on this branch.
  • Link audit over all 116 tracked .md files: 49 findings on develop, 7 here. The 7 are the PR-template link above, five ../../issues-style links in CONTRIBUTING.md that resolve in GitHub's URL space (each fetched: 200), and a placeholder in a skill's prose.
  • cargo fmt --all --check, cargo clippy --all-targets with 0 warnings, cargo test --all 4261 passed, 0 failed.
  • rtk git --help prints the -C line unchanged.

🤖 Generated with Claude Code

Comment thread .github/PULL_REQUEST_TEMPLATE.md Outdated
@aeppling aeppling self-assigned this Sep 11, 2026
@KuSh KuSh changed the title docs: fix relative links that never resolved docs: fix doc references that never resolved, and gate cargo doc in CI Sep 12, 2026
@KuSh
KuSh force-pushed the docs/fix-relative-links branch 2 times, most recently from 77dd0ea to 8773840 Compare September 17, 2026 22:40
@KuSh
KuSh requested a review from aeppling September 18, 2026 00:29
@KuSh
KuSh force-pushed the docs/fix-relative-links branch from 8773840 to 717e1e9 Compare September 28, 2026 01:03
@KuSh
KuSh force-pushed the docs/fix-relative-links branch from 717e1e9 to a667110 Compare October 7, 2026 07:38

@aeppling aeppling left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lgtm

Fixes 42 broken relative links and anchors in the markdown docs and the 20
doc comments that make `cargo doc` fail under `warnings = "deny"`, and adds a
`rustdoc` CI job so the second class cannot come back unnoticed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@KuSh
KuSh force-pushed the docs/fix-relative-links branch from a667110 to f850592 Compare October 8, 2026 17:34
@KuSh
KuSh merged commit b9fb519 into rtk-ai:develop Oct 8, 2026
12 checks passed
@KuSh
KuSh deleted the docs/fix-relative-links branch October 8, 2026 17:45
@rtk-release-bot rtk-release-bot Bot mentioned this pull request Oct 8, 2026
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.

2 participants