Comments (7)
cargo-rdme implements README generation and replaces intralinks with links to docs.rs: https://github.com/orium/cargo-rdme#intralinks
Disclaimer: I'm the author of the crate :)
from cargo-readme.
An option to remove the intra-doc links would be a decent middle-ground, so that I don't have a bunch of broken API docs links in my README, but to do that accurately would require parsing the markdown as markdown instead of the simple line-based processing procedure taken currently, due to the existence of the reference-style markdown links.
from cargo-readme.
I figured out a pretty easy workaround. Stick a Markdown reference-style link in your template for all the types you refer to. This lets you refer to a specific docs.rs version or even the latest.
Here's how I did this for thunderdome
: https://github.com/LPGhatguy/thunderdome/blob/21606a1172521772dfae79d9a247e6ab12a641b0/README.tpl#L5-L6
from cargo-readme.
Shameless plug: cargo-rdme not only generates intralinks to docs.rs, it also has a flag (or configuration file) to strip the intralinks if you so choose.
It also strips out the #
in rust code. And it also tags the markdown code block as rust
if that was not the case (even if it is just tagged as should_panic
or no_run
or all the other stuff rustdoc
recognizes as rust code).
from cargo-readme.
It would be great to have an ability to customize the docs path (instead of hardcoding docs.rs
) - we use live docs in a custom github pages location and would prefer to link our readme to that.
from cargo-readme.
or wherever else the API documentation is hosted.
Maybe via a command-line option, or it can read it from the Cargo.toml
parameter. However I agree it would make more sense to link to docs generated from the latest commit, if they are available, instead of the docs URL in the manifest.
from cargo-readme.
A way to make this more pleasant without requiring too much work would be to just strip out intra doc links.
Could also strip out #
lines from rust code samples.
from cargo-readme.
Related Issues (20)
- Include feature gated docs
- Feature Request: --locked flag for use in CI HOT 1
- Feature request: output binaries' `--help` into template
- parse the whole file HOT 2
- Workspace usage error HOT 2
- Missing git tag 3.2.0 HOT 3
- Thank You! 🎉
- cargo-readme does not read #![doc = r#"documentation"#] attributes HOT 2
- Document supported badges
- coveralls badge `branch` in URL query param
- feature request: convert [`Foo`] to a link to the docs HOT 3
- Generate rustdoc from README? HOT 1
- Support `document-features`
- Code fences have "rust" added to closing fence HOT 1
- Empty hidden lines in code blocks aren't hidden HOT 1
- stops parsing after first //! block
- Workspace inheritance breaks cargo readme HOT 3
- Missing git tag 3.3.0 HOT 1
- For crates with binaries, allow writing of --help docs to README
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cargo-readme.