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

Support multiple sources with conflicting crates #153

Open
ChrisGreenaway opened this issue Aug 3, 2019 · 1 comment
Open

Support multiple sources with conflicting crates #153

ChrisGreenaway opened this issue Aug 3, 2019 · 1 comment

Comments

@ChrisGreenaway
Copy link
Collaborator

It should be possible for cargo-local-registry to have multiple different versions of a crate (i.e. the same crate with the same version from multiple sources).

One way to achieve this would be to have multiple subdirectories in the output registry directory when there are multiple sources (different registries, git repos etc.) - one for each source. The output from running cargo-local-registry would output a .cargo/config file that mapped each of the source registries to the appropriate subdirectory.

I think we should keep the current behaviour (i.e. no subdirectories) when there is just one source. Additionally, we probably want to have a repeatable mapping from the details of a source to the name of the subdirectory, which would have to include, for example, for a git source, the branch, tag or revision. Further, the directory name would need to be valid on all supported filesystems - so I guess at least on UNIX and Windows (others?).

Please see the discussion on #134 for the initial discussion of this idea.

@ChrisGreenaway
Copy link
Collaborator Author

Just noticed that cargo-vendor appears to have something similar with their --no-merge-sources option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant