mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-05-05 11:40:04 +00:00
feat: Support install directly from git repo (#1162)
Fixed #3 Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
dd35fba232
commit
ca00cbaccc
22 changed files with 1810 additions and 28 deletions
|
@ -10,7 +10,9 @@ use tokio::{
|
|||
|
||||
use crate::{
|
||||
fetchers::{Data, Fetcher, TargetData},
|
||||
helpers::{gh_api_client::GhApiClient, jobserver_client::LazyJobserverClient, remote::Client},
|
||||
helpers::{
|
||||
self, gh_api_client::GhApiClient, jobserver_client::LazyJobserverClient, remote::Client,
|
||||
},
|
||||
manifests::cargo_toml_binstall::PkgOverride,
|
||||
DesiredTargets,
|
||||
};
|
||||
|
@ -19,6 +21,13 @@ pub mod resolve;
|
|||
|
||||
pub type Resolver = fn(Client, GhApiClient, Arc<Data>, Arc<TargetData>) -> Arc<dyn Fetcher>;
|
||||
|
||||
#[non_exhaustive]
|
||||
pub enum CargoTomlFetchOverride {
|
||||
#[cfg(feature = "git")]
|
||||
Git(helpers::git::GitUrl),
|
||||
Path(PathBuf),
|
||||
}
|
||||
|
||||
pub struct Options {
|
||||
pub no_symlinks: bool,
|
||||
pub dry_run: bool,
|
||||
|
@ -28,7 +37,7 @@ pub struct Options {
|
|||
pub no_track: bool,
|
||||
|
||||
pub version_req: Option<VersionReq>,
|
||||
pub manifest_path: Option<PathBuf>,
|
||||
pub cargo_toml_fetch_override: Option<CargoTomlFetchOverride>,
|
||||
pub cli_overrides: PkgOverride,
|
||||
|
||||
pub desired_targets: DesiredTargets,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue