mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-04-21 04:58:42 +00:00
Add HTTPCacher
to binstalk_fetchers::Fetcher::new
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
a6e93a2881
commit
ce1ae9e0ca
5 changed files with 5 additions and 1 deletions
|
@ -5,6 +5,7 @@ use std::sync::{
|
|||
|
||||
use binstalk_downloader::gh_api_client::{GhReleaseArtifact, HasReleaseArtifact};
|
||||
pub(super) use binstalk_downloader::{
|
||||
cacher::HTTPCacher,
|
||||
download::{Download, ExtractedFiles},
|
||||
gh_api_client::GhApiClient,
|
||||
remote::{Client, Url},
|
||||
|
|
|
@ -26,7 +26,7 @@ struct Artifact {
|
|||
}
|
||||
|
||||
#[derive(Clone, Debug)]
|
||||
pub(super) enum DistManifest {
|
||||
enum DistManifest {
|
||||
NotSupported(Format),
|
||||
/// Key: name of the binary
|
||||
Binaries(BTreeMap<CompactString, Binary>),
|
||||
|
|
|
@ -102,6 +102,7 @@ impl super::Fetcher for GhCrateMeta {
|
|||
fn new(
|
||||
client: Client,
|
||||
gh_api_client: GhApiClient,
|
||||
_cacher: HTTPCacher,
|
||||
data: Arc<Data>,
|
||||
target_data: Arc<TargetDataErased>,
|
||||
signature_policy: SignaturePolicy,
|
||||
|
|
|
@ -96,6 +96,7 @@ pub trait Fetcher: Send + Sync {
|
|||
fn new(
|
||||
client: Client,
|
||||
gh_api_client: GhApiClient,
|
||||
cacher: HTTPCacher,
|
||||
data: Arc<Data>,
|
||||
target_data: Arc<TargetDataErased>,
|
||||
signature_policy: SignaturePolicy,
|
||||
|
|
|
@ -82,6 +82,7 @@ impl super::Fetcher for QuickInstall {
|
|||
fn new(
|
||||
client: Client,
|
||||
gh_api_client: GhApiClient,
|
||||
_cacher: HTTPCacher,
|
||||
data: Arc<Data>,
|
||||
target_data: Arc<TargetDataErased>,
|
||||
signature_policy: SignaturePolicy,
|
||||
|
|
Loading…
Add table
Reference in a new issue