From 7daddbe6208911d16ab2fc4ae37c16ebc950936c Mon Sep 17 00:00:00 2001 From: David Knaack Date: Thu, 13 Apr 2023 10:41:25 +0200 Subject: [PATCH] build(deps): update rust crate starship-battery to 0.8.0 (#5106) --- Cargo.lock | 60 +++++++++++------------------------------- Cargo.toml | 2 +- src/modules/battery.rs | 4 --- 3 files changed, 17 insertions(+), 49 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 927dbf04..5c1983f6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -464,20 +464,14 @@ dependencies = [ [[package]] name = "core-foundation" -version = "0.7.0" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57d24c7a13c43e870e37c1556b74555437870a04514f7685f5b354e090567171" +checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" dependencies = [ - "core-foundation-sys 0.7.0", + "core-foundation-sys", "libc", ] -[[package]] -name = "core-foundation-sys" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3a71ab494c0b5b860bdc8407ae08978052417070c2ced38573a9157ad75b8ac" - [[package]] name = "core-foundation-sys" version = "0.8.4" @@ -1325,7 +1319,7 @@ checksum = "0f3034d4d935aef2c7bf719aaa54b88c520e82413118d886ae880a31d5bdee57" dependencies = [ "gix-command", "gix-config-value", - "nix 0.26.2", + "nix", "parking_lot", "thiserror", ] @@ -1548,7 +1542,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0722cd7114b7de04316e7ea5456a0bbb20e4adb46fd27a3697adb812cff0f37c" dependencies = [ "android_system_properties", - "core-foundation-sys 0.8.4", + "core-foundation-sys", "iana-time-zone-haiku", "js-sys", "wasm-bindgen", @@ -1771,10 +1765,10 @@ dependencies = [ ] [[package]] -name = "mach" -version = "0.3.2" +name = "mach2" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b823e83b2affd8f40a9ee8c29dbc56404c1e34cd2710921f2801e2cf29527afa" +checksum = "6d0d1830bcd151a6fc4aea1369af235b36c1528fe976b8ff678683c9995eade8" dependencies = [ "libc", ] @@ -1809,15 +1803,6 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a64a92489e2744ce060c349162be1c5f33c6969234104dbd99ddb5feb08b8c15" -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - [[package]] name = "memoffset" version = "0.7.1" @@ -1878,19 +1863,6 @@ dependencies = [ "syn 1.0.109", ] -[[package]] -name = "nix" -version = "0.23.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f3790c00a0150112de0f4cd161e3d7fc4b2d8a5542ffc35f099a2562aecb35c" -dependencies = [ - "bitflags", - "cc", - "cfg-if", - "libc", - "memoffset 0.6.5", -] - [[package]] name = "nix" version = "0.26.2" @@ -2787,7 +2759,7 @@ dependencies = [ "indexmap", "log", "mockall", - "nix 0.26.2", + "nix", "notify-rust", "nu-ansi-term", "once_cell", @@ -2828,16 +2800,16 @@ dependencies = [ [[package]] name = "starship-battery" -version = "0.7.9" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3336198ad004af4447ae69be4f4e562c26814570f8f0c1e37858405a294e015d" +checksum = "417551ac84efa1810d79d04555d36cbc83ec5a323f2ef9ee7318e34055461b6f" dependencies = [ "cfg-if", "core-foundation", "lazycell", "libc", - "mach", - "nix 0.23.2", + "mach2", + "nix", "num-traits", "uom", "winapi", @@ -3242,9 +3214,9 @@ checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" [[package]] name = "uom" -version = "0.30.0" +version = "0.34.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e76503e636584f1e10b9b3b9498538279561adcef5412927ba00c2b32c4ce5ed" +checksum = "e8f50eddd69f656ee545f7663ea5fefb7c789bc1a0d11124e049715f563a16a4" dependencies = [ "num-traits", "typenum", @@ -3671,7 +3643,7 @@ dependencies = [ "futures-sink", "futures-util", "hex", - "nix 0.26.2", + "nix", "once_cell", "ordered-stream", "rand", diff --git a/Cargo.toml b/Cargo.toml index 8d81bf0d..bb9cc26b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -76,7 +76,7 @@ sha1 = "0.10.5" shadow-rs = { version = "0.21.0", default-features = false } # battery is optional (on by default) because the crate doesn't currently build for Termux # see: https://github.com/svartalf/rust-battery/issues/33 -starship-battery = { version = "0.7.9", optional = true } +starship-battery = { version = "0.8.0", optional = true } strsim = "0.10.0" systemstat = "=0.2.3" terminal_size = "0.2.6" diff --git a/src/modules/battery.rs b/src/modules/battery.rs index 0800b2d4..0ccad6a4 100644 --- a/src/modules/battery.rs +++ b/src/modules/battery.rs @@ -37,10 +37,6 @@ pub fn module<'a>(context: &'a Context) -> Option> { .or(Some(config.discharging_symbol)), battery::State::Unknown => Some(config.unknown_symbol), battery::State::Empty => Some(config.empty_symbol), - _ => { - log::debug!("Unhandled battery state `{}`", state); - None - } }, _ => None, })