mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-04-20 20:48:43 +00:00
Merge pull request #122 from somehowchris/feature/ignore-yanked
fix: ignore crate version if yanked
This commit is contained in:
commit
60fc30461e
1 changed files with 7 additions and 1 deletions
|
@ -83,7 +83,13 @@ pub async fn fetch_crate_cratesio(
|
||||||
};
|
};
|
||||||
|
|
||||||
// Locate matching version
|
// Locate matching version
|
||||||
let version_iter = base_info.versions().iter().map(|v| v.version());
|
let version_iter = base_info.versions().iter().filter_map(|v| {
|
||||||
|
if !v.is_yanked() {
|
||||||
|
Some(v.version())
|
||||||
|
} else {
|
||||||
|
None
|
||||||
|
}
|
||||||
|
});
|
||||||
let version_name = find_version(version_req, version_iter)?;
|
let version_name = find_version(version_req, version_iter)?;
|
||||||
|
|
||||||
// Build crates.io api client
|
// Build crates.io api client
|
||||||
|
|
Loading…
Add table
Reference in a new issue