From d091d591742115ff4928793a67646f6f63c2a0c8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 27 Nov 2024 17:43:17 +0100 Subject: [PATCH] Bump cargo_metadata from 0.18.1 to 0.19.0 (#1828) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Bump cargo_metadata from 0.18.1 to 0.19.0 Bumps [cargo_metadata](https://github.com/oli-obk/cargo_metadata) from 0.18.1 to 0.19.0. - [Release notes](https://github.com/oli-obk/cargo_metadata/releases) - [Changelog](https://github.com/oli-obk/cargo_metadata/blob/main/CHANGELOG.md) - [Commits](https://github.com/oli-obk/cargo_metadata/compare/0.18.1...0.19.0) --- updated-dependencies: - dependency-name: cargo_metadata dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * Migrate to enum instead of str * Migrate to enum instead of str --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Michael Müller --- Cargo.lock | 6 +++--- crates/build/Cargo.toml | 2 +- crates/build/src/crate_metadata.rs | 3 ++- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2fa6f6cc9..680291d63 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1626,9 +1626,9 @@ dependencies = [ [[package]] name = "cargo_metadata" -version = "0.18.1" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d886547e41f740c616ae73108f6eb70afe6d940c7bc697cb30f13daec073037" +checksum = "afc309ed89476c8957c50fb818f56fe894db857866c3e163335faa91dc34eb85" dependencies = [ "camino", "cargo-platform", @@ -1930,7 +1930,7 @@ dependencies = [ "anyhow", "blake2", "bollard", - "cargo_metadata 0.18.1", + "cargo_metadata 0.19.0", "clap", "colored", "contract-metadata", diff --git a/crates/build/Cargo.toml b/crates/build/Cargo.toml index aff9b8fe6..98413e049 100644 --- a/crates/build/Cargo.toml +++ b/crates/build/Cargo.toml @@ -17,7 +17,7 @@ include = ["Cargo.toml", "src/**/*.rs", "README.md", "LICENSE", "build.rs", "tem regex = "1" anyhow = "1.0.83" blake2 = "0.10.6" -cargo_metadata = "0.18.1" +cargo_metadata = "0.19.0" colored = "2.1.0" clap = { version = "4.5.4", features = ["derive", "env"] } duct = "0.13.7" diff --git a/crates/build/src/crate_metadata.rs b/crates/build/src/crate_metadata.rs index fc2b756a4..704993abb 100644 --- a/crates/build/src/crate_metadata.rs +++ b/crates/build/src/crate_metadata.rs @@ -26,6 +26,7 @@ use cargo_metadata::{ Metadata as CargoMetadata, MetadataCommand, Package, + TargetKind, }; use semver::Version; use serde_json::{ @@ -77,7 +78,7 @@ impl CrateMetadata { if let Some(lib_name) = &root_package .targets .iter() - .find(|target| target.kind.iter().any(|t| t == "lib")) + .find(|target| target.kind.iter().any(|f| *f == TargetKind::Lib)) { if lib_name.name != root_package.name { // warn user if they still specify a lib name different from the