mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-04-24 22:30:03 +00:00
Fix skipping optional dep: Skip fetcher if they provide 0 bin (#446)
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
af3316a8f3
commit
abd50a72ec
1 changed files with 15 additions and 7 deletions
|
@ -243,13 +243,21 @@ async fn resolve_inner(
|
||||||
.await
|
.await
|
||||||
{
|
{
|
||||||
Ok(bin_files) => {
|
Ok(bin_files) => {
|
||||||
return Ok(Resolution::Fetch {
|
if !bin_files.is_empty() {
|
||||||
fetcher,
|
return Ok(Resolution::Fetch {
|
||||||
package,
|
fetcher,
|
||||||
name: crate_name.name,
|
package,
|
||||||
version_req: version_req.to_compact_string(),
|
name: crate_name.name,
|
||||||
bin_files,
|
version_req: version_req.to_compact_string(),
|
||||||
})
|
bin_files,
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
warn!(
|
||||||
|
"Error when checking binaries provided by fetcher {}: \
|
||||||
|
The fetcher does not provide any optional binary",
|
||||||
|
fetcher.source_name(),
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Err(err) => {
|
Err(err) => {
|
||||||
warn!(
|
warn!(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue