From fff0c6e2cb1ff9f5daf05ac39756014bc1d07b04 Mon Sep 17 00:00:00 2001 From: Wind Date: Wed, 18 Dec 2024 23:09:50 +0800 Subject: [PATCH] update shadow-rs to 0.37 (#14617) --- Cargo.lock | 8 ++++---- crates/nu-cmd-lang/Cargo.toml | 6 +++--- crates/nu-cmd-lang/build.rs | 7 ++++--- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d37c10a46f..9cc6b8c04c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2458,9 +2458,9 @@ checksum = "7655c9839580ee829dfacba1d1278c2b7883e50a277ff7541299489d6bdfdc45" [[package]] name = "is_debug" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06d198e9919d9822d5f7083ba8530e04de87841eaf21ead9af8f2304efd57c89" +checksum = "e8ea828c9d6638a5bd3d8b14e37502b4d56cae910ccf8a5b7f51c7a0eb1d0508" [[package]] name = "is_executable" @@ -6292,9 +6292,9 @@ dependencies = [ [[package]] name = "shadow-rs" -version = "0.36.0" +version = "0.37.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58cfcd0643497a9f780502063aecbcc4a3212cbe4948fd25ee8fd179c2cf9a18" +checksum = "974eb8222c62a8588bc0f02794dd1ba5b60b3ec88b58e050729d0907ed6af610" dependencies = [ "const_format", "is_debug", diff --git a/crates/nu-cmd-lang/Cargo.toml b/crates/nu-cmd-lang/Cargo.toml index 00ba449785..95bf4dd342 100644 --- a/crates/nu-cmd-lang/Cargo.toml +++ b/crates/nu-cmd-lang/Cargo.toml @@ -21,10 +21,10 @@ nu-protocol = { path = "../nu-protocol", version = "0.100.1", default-features = nu-utils = { path = "../nu-utils", version = "0.100.1", default-features = false } itertools = { workspace = true } -shadow-rs = { version = "0.36", default-features = false } +shadow-rs = { version = "0.37", default-features = false } [build-dependencies] -shadow-rs = { version = "0.36", default-features = false } +shadow-rs = { version = "0.37", default-features = false } [features] default = ["os"] @@ -42,4 +42,4 @@ mimalloc = [] trash-support = [] sqlite = [] static-link-openssl = [] -system-clipboard = [] \ No newline at end of file +system-clipboard = [] diff --git a/crates/nu-cmd-lang/build.rs b/crates/nu-cmd-lang/build.rs index 0d49abde0b..8f2339bae3 100644 --- a/crates/nu-cmd-lang/build.rs +++ b/crates/nu-cmd-lang/build.rs @@ -1,12 +1,13 @@ use std::process::Command; -fn main() -> shadow_rs::SdResult<()> { +fn main() { // Look up the current Git commit ourselves instead of relying on shadow_rs, // because shadow_rs does it in a really slow-to-compile way (it builds libgit2) let hash = get_git_hash().unwrap_or_default(); println!("cargo:rustc-env=NU_COMMIT_HASH={hash}"); - - shadow_rs::new() + shadow_rs::ShadowBuilder::builder() + .build() + .expect("shadow builder build should success"); } fn get_git_hash() -> Option {