Closed
Description
If you have an alternative registry configured and want to patch a crate in it, you currently have to spell out the entire URL:
.cargo/config
[registries.foobar]
index = "https://foobar.com/some-long-url/index"
Cargo.toml
...
[dependencies]
thingy = { version = "0.1", registry = "foobar" }
[patch."https://foobar.com/some-long-url/index"]
thingy = { git = "https://somewhere-else.com" }
But it's a bit annoying to have to write the whole URL around (and is the only place you're allowed to use the alternative registry URL directly in Cargo.toml). It'd be great if this worked instead:
[patch.foobar]
thingy = { git = "https://somewhere-else.com" }