-
Notifications
You must be signed in to change notification settings - Fork 20
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
ci: add lychee
#200
base: main
Are you sure you want to change the base?
ci: add lychee
#200
Conversation
# Run `lychee` at: | ||
# 1. The repo root (excluding `target/`) | ||
# 2. Cuprate's cargo documentation | ||
- name: Lychee | ||
run: | | ||
lychee . --exclude target | ||
lychee target/doc/cuprate_* |
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.
This is put inside ci.yml
because we need access to target/doc
.
This allows for scanning generated documentation, e.g. rpc/types
have links that are generated with macros.
lychee.toml
Outdated
# Exclude URLs and mail addresses from checking (supports regex). | ||
exclude = ["file://"] |
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.
Crate type links are excluded since our cargo doc
CI catches it.
- name: Install dependencies (All) | ||
run: cargo install lychee |
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.
I'm leaning towards not mentioning this in CONTRIBUTING.md
since:
- Wrong links are infrequent
- This CI will show them anyway
/// <https://cuprate.github.io/monero-book/consensus_rules/transactions/decoys.html> | ||
/// <https://cuprate.github.io/monero-book/consensus_rules/transactions/inputs.html> |
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.
decoys.html
doesn't exist anymore, is this a good replacement?
Going to fix CI first, sorry. |
What
lychee
to CIlychee.toml
config fileThis checks if links are correct, this includes books, cargo docs, code, etc.