Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: give relative paths explicit .md suffix so they work in GitHub web UI too [ciskip] #812

Merged
merged 60 commits into from
Jun 23, 2021

Conversation

jessicaschilling
Copy link
Contributor

@jessicaschilling jessicaschilling commented Jun 22, 2021

Well, this was painful. 😭

This PR replaces html-style relative paths throughout the entirety of the docs with ones that are "explicit" in two ways:

  • have correct use of slashes, dots etc at the beginning to properly traverse directory structure, rather than relying on Vuepress kindly making its usual assumptions about relative paths
  • include .md as appropriate in the actual file name

This enables people who are reading the docs in GitHub's web UI to actually have relative links that work. (VuePress is clever enough to strip out .md etc on site build so everything works correctly on docs.ipfs.io.)

Example:

[`ipfs pin -r`](/reference/cli/#ipfs-pin)

becomes

[`ipfs pin -r`](./reference/cli.md#ipfs-pin)

As this was an entirely manual process, I may have missed a few. However, have checked all modifications in this PR both on a local site build and on GitHub web UI.

Also adds guidance for docs writers on the "Grammar, formatting, and style" page on adding relative paths (example).

ref #669 (comment) from @kvutien.

@cwaring
Copy link
Member

cwaring commented Jun 22, 2021

💯🙏🏻

@jessicaschilling jessicaschilling marked this pull request as draft June 22, 2021 20:20
@filecorgi

This comment has been minimized.

@johnnymatthews johnnymatthews changed the title fix: give relative paths explicit .md suffix so they work in GitHub web UI too fix: give relative paths explicit .md suffix so they work in GitHub web UI too [ciskip] Jun 23, 2021
@johnnymatthews johnnymatthews merged commit f3d81ec into main Jun 23, 2021
@johnnymatthews johnnymatthews deleted the fix/broken-links-669 branch June 23, 2021 18:14
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.

4 participants