-
Notifications
You must be signed in to change notification settings - Fork 24
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
Normalize links to other ADR documents #318
Conversation
.readme.templ
Outdated
@@ -25,6 +25,6 @@ We want to move away from using these to document individual minor decisions, mo | |||
|
|||
## Template | |||
|
|||
Please see the [template](adr-template.md). The template body is a guideline. Feel free to add sections as you feel appropriate. Look at the other ADRs for examples. However, the initial Table of metadata and header format is required to match. | |||
Please see the [template](./adr-template.md). The template body is a guideline. Feel free to add sections as you feel appropriate. Look at the other ADRs for examples. However, the initial Table of metadata and header format is required to match. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious why specifically ./x
, when relative worked fine before? Browsers will just remove it again when building the links
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
./
is that it is a tad more expressive, and GitHub will still link properly1.
./
is more easily searched for when relative links containing files in the same directory are ever moved into other locations. e.g. if a particular ADR, or all ADRs, are moved to their own sub-directory.
I am entirely happy with removing ./
from all links if this reasoning doesn't merit the change, but I think there are some upsides to using ./
, from a maintainability perspective.
Footnotes
-
GitHub even scrubs
./
from the URL... ↩
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are fine examples of why, but no contributor will do this as its unusual :) I prefer to stick to normal paths that is likely to match what contributors would also do
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is fair, I'll be glad to rewrite the commit to omit ./
. I don't think any contributor even had a common method for linking other ADRs, as it was a bit all over the place - so people might end up linking to a GitHub page in the end after all 🤣
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed many ways, but none of them ever used ./
which suggests it's pretty certain they won't in future either :)
6fa89ad
to
b93f987
Compare
If you're feeling generous here are a few other broken things.
|
Fix some broken links Links to other ADR documents were normalized based off of relative directories which GitHub supports: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-readmes#relative-links-and-image-paths-in-readme-files
b93f987
to
451f76d
Compare
Ah, these flew right past me - I've fixed those links too. Thanks! |
Thank you @bannatech |
Links to other ADR documents were normalized based off of relative directories which GitHub supports:
https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-readmes#relative-links-and-image-paths-in-readme-files