Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upAllow renaming crates in the dependencies section #1311
Comments
This comment has been minimized.
This comment has been minimized.
|
What's the intent of this? What would it do differently than: [dependencies]
rustc-serialize = "*" |
This comment has been minimized.
This comment has been minimized.
|
This is actually currently possible as: [dependencies.foo]
version = "..."Although if you mean renaming crates that's a separate issue :) |
alexcrichton
closed this
Feb 16, 2015
This comment has been minimized.
This comment has been minimized.
|
@alexcrichton I do mean renaming crates, please re-open :P @tomjakubowski It would create a crate named |
alexcrichton
reopened this
Feb 23, 2015
alexcrichton
changed the title
Allow specifying crates.io packages in a dependency section
Allow renaming crates in the dependencies section
Feb 23, 2015
This comment has been minimized.
This comment has been minimized.
|
(updated with what I believe to be a more accurate title) |
alexcrichton
added
the
A-configuration
label
Feb 23, 2015
This comment has been minimized.
This comment has been minimized.
|
Sure, this title works. But a side effect of this is to permit the specification of crates.io as the origin of a dependency named in its own subsection (like |
This comment has been minimized.
This comment has been minimized.
|
This is a wanted feature for the following scenario: Your crate provides an optional feature named "serde" that enables serde integration. In the next version you want to depend two crates for the "serde" feature, serde itself and another crate. Renaming the serde dependency would make the serde feature name available to do this transition smoothly. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Yes, it's considering the same kinds of questions I have (but in greater depth). |
This comment has been minimized.
This comment has been minimized.
|
Someone was trying to depend on both |
retep998
referenced this issue
Sep 17, 2017
Closed
Tracking issue for RFC 2126: Clarify and streamline paths and visibility #44660
aturon
referenced this issue
Jan 8, 2018
Closed
Tracking issue for RFC 2141: Add support to Cargo for alternative registries #44931
This comment has been minimized.
This comment has been minimized.
evmar
commented
Jan 31, 2018
|
Another example: a program that compared gif implementations might want to use both https://github.com/Geal/gif.rs/blob/master/Cargo.toml and https://github.com/PistonDevelopers/image-gif/blob/master/Cargo.toml, both of which claim the name "gif". |
This comment has been minimized.
This comment has been minimized.
|
I've been having a think about this lately, and wondering the best way to do this... it seems the crate name (the one used in |
This comment has been minimized.
This comment has been minimized.
|
FWIW I have a PR open for this, and any comments would be much appreciated! |
This comment has been minimized.
This comment has been minimized.
|
@alexcrichton Doh, I wish I had known sooner! I just implemented it here too. Oh well, at least someone has done it. Thanks. |
alexreg
referenced this issue
Feb 8, 2018
Merged
Implement renaming dependencies in the manifest #4953
bors
added a commit
that referenced
this issue
Feb 19, 2018
This comment has been minimized.
This comment has been minimized.
|
@alexcrichton I think this should be closed now that #4953 is merged, no? |
This comment has been minimized.
This comment has been minimized.
|
Indeed! |
alexcrichton
closed this
Feb 28, 2018
This comment has been minimized.
This comment has been minimized.
dragostis
commented
Apr 24, 2018
|
The example in #4953 fails with:
|
This comment has been minimized.
This comment has been minimized.
|
@dragostis could you open a separate issue for that, so that this does not fall through the cracks? |
This comment has been minimized.
This comment has been minimized.
dragostis
commented
Apr 24, 2018
|
cc #5413 |
alexchandel commentedFeb 14, 2015
Something like this should work:
At the moment, only
pathandgitattributes are supported.