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

Sources and registries documentation suggestions #6862

Closed
fluffysquirrels opened this issue Apr 18, 2019 · 2 comments · Fixed by #6865
Closed

Sources and registries documentation suggestions #6862

fluffysquirrels opened this issue Apr 18, 2019 · 2 comments · Fixed by #6865
Labels
A-documenting-cargo-itself Area: Cargo's documentation

Comments

@fluffysquirrels
Copy link
Contributor

fluffysquirrels commented Apr 18, 2019

CC: @ehuss as discussed on discord

These are suggestions only, happy to discuss.

Source replacement:

  • Define a "source" on this page, perhaps copying the definition from the glossary.
  • There are two blocks of toml near the top of this page that define the configuration for source replacement. Merge these.
  • "[P]rivate registry support is planned for a future version of Cargo.": the future is here! Link to the registries documentation.
  • Describe when sources are used: when cargo fetches source code for dependencies to build them. Are there other cases? List some of the commands that use sources.
  • Add links to cargo-local-registry and cargo-vendor on crates.io

Registries:

  • Links to cargo-local-registry EDIT: I don't think local registries are supported by e.g. cargo publish and cargo login, so this is not relevant.

I'm happy to submit a PR for these. I may have other suggestions as I start to write.

Hope that helps!

@ehuss
Copy link
Contributor

ehuss commented Apr 20, 2019

These sound great!

Are there other cases?

Just for dependencies.

Add links to cargo-local-registry and cargo-vendor on crates.io

The source replacement page does link to both of the commands. Maybe because the CSS style for code overrides the a link styling it's hard to see. I believe this is due to rust-lang/mdBook#537.

Thanks! Any help with clarifying and expanding the docs is greatly appreciated!

@ehuss ehuss added the A-documenting-cargo-itself Area: Cargo's documentation label Apr 20, 2019
@fluffysquirrels
Copy link
Contributor Author

@ehuss, thanks for the clarifications.

Given the mdBook issue hasn't been updated in 6 months, is it worth sidestepping it and rendering the links like:

The primary way to manage and create local registry sources is through the cargo-local-registry subcommand, available as a crate on crates.io, and can be installed with cargo install cargo-local-registry.

I'm working on the other edits.

fluffysquirrels pushed a commit to fluffysquirrels/cargo that referenced this issue Apr 22, 2019
bors added a commit that referenced this issue Apr 29, 2019
Cargo book: source replacement

Closes #6862
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-documenting-cargo-itself Area: Cargo's documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants