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

Include README as crate doc #4

Merged
merged 2 commits into from
Apr 1, 2024

Conversation

Velnbur
Copy link
Contributor

@Velnbur Velnbur commented Mar 31, 2024

This change makes two main profits:

  • The entry point in the doc site of the crate always will be its README which will exclude the need of repeting the same things inside the lib.rs and README itself.

  • After inclusion of the README as a doc, all the code inside it will be evaludated as Rust doc test which will keep the code examples up-to-date.

This change makes two main profits:

* The entry point in the doc site of the crate always will be its README
which will exclude the need of repeting the same things inside the
`lib.rs` and README itself.

* After inclusion of the README as a doc, all the code inside it will be
evaludated as Rust _doc test_ which will keep the code examples
up-to-date.
@Velnbur
Copy link
Contributor Author

Velnbur commented Mar 31, 2024

After running cargo test and cargo test --doc particularly, I get the passed test of code inside README:

image

@Velnbur
Copy link
Contributor Author

Velnbur commented Mar 31, 2024

Also, the entry page of the doc-site after running the cargo doc --open --no-deps likes like this:

image

@olegfomenko olegfomenko merged commit c649684 into distributed-lab:master Apr 1, 2024
1 check passed
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.

None yet

2 participants