mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-05-07 12:40:04 +00:00
feat: Impl support for alternative registries (#1184)
Fixed #1168 Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
d4ffc68129
commit
01a87ac606
18 changed files with 779 additions and 132 deletions
|
@ -19,7 +19,6 @@ use tracing::{debug, info, instrument, warn};
|
|||
|
||||
use crate::{
|
||||
bins,
|
||||
drivers::fetch_crate_cratesio,
|
||||
errors::{BinstallError, VersionParseError},
|
||||
fetchers::{Data, Fetcher, TargetData},
|
||||
helpers::{self, download::ExtractedFiles, remote::Client, target_triple::TargetTriple},
|
||||
|
@ -379,12 +378,10 @@ impl PackageInfo {
|
|||
.await??
|
||||
}
|
||||
None => {
|
||||
Box::pin(fetch_crate_cratesio(
|
||||
client,
|
||||
&name,
|
||||
version_req,
|
||||
&opts.crates_io_rate_limit,
|
||||
))
|
||||
Box::pin(
|
||||
opts.registry
|
||||
.fetch_crate_matched(client, &name, version_req),
|
||||
)
|
||||
.await?
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue