rust-lang / rust-lang/rust-clippy

"View Source" links on website always link to dynamic `master` branch

Open
#16,882 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-documentation
Dominant language
Rust
Stars
13.5k
Forks
2.2k
Avg merge
2d 10h
Merged PRs (30d)
32

Description

"View Source" links on the website always lead to master branch in the GitHub repository, which is subject to changes over time.

For example, for collapsible_match on Rust 1.95.0, the source link points to https://github.com/rust-lang/rust-clippy/blob/master/clippy_lints/src/matches/mod.rs#L659, which is not the expected location as the file was updated since the tag was published. Pointing to the tag (https://github.com/rust-lang/rust-clippy/blob/rust-1.95.0/clippy_lints/src/matches/mod.rs#L659) would ensure that the location stays valid over time.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how the website generates the “View Source” links for lint pages, using the collapsible_match example in the issue. Check how the Rust 1.95.0 release or tag is represented, then verify that the generated link uses rust-1.95.0 rather than master and remains valid for the published page.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
documentation
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
64/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.