From 03fc1b1ec8d1961571fba1b51f7dcb2aba6b58e9 Mon Sep 17 00:00:00 2001 From: Moritz Ruth Date: Sat, 18 Mar 2023 21:36:35 +0100 Subject: [PATCH] v1.0.0 --- Cargo.lock | 2 +- Cargo.toml | 7 ++++--- README.md | 1 - src/modules/info.rs | 1 - src/mqtt.rs | 2 +- src/util.rs | 7 ------- 6 files changed, 6 insertions(+), 14 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 4c1263d..c6a4c68 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -667,7 +667,7 @@ checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" [[package]] name = "hassliebe" -version = "0.1.0" +version = "1.0.0" dependencies = [ "anyhow", "base64", diff --git a/Cargo.toml b/Cargo.toml index a249565..c299466 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,10 +1,11 @@ [package] name = "hassliebe" -version = "0.1.0" +version = "1.0.0" edition = "2021" +license = "BlueOak-1.0.0" +authors = ["Moritz Ruth "] homepage = "https://git.moritzruth.de/moritzruth/Hassliebe" - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +repository = "https://git.moritzruth.de/moritzruth/Hassliebe" [features] dry_run = [] # will prevent some actions like shutting down diff --git a/README.md b/README.md index 7b5eb1e..2d0fb1b 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,6 @@ - [ ] Media control (MPRIS) - [ ] PipeWire control - [ ] File watcher -- [ ] Fallback MQTT broker address Ideas: diff --git a/src/modules/info.rs b/src/modules/info.rs index 07cbf10..7add55b 100644 --- a/src/modules/info.rs +++ b/src/modules/info.rs @@ -1,4 +1,3 @@ -use std::fs::ReadDir; use std::time::Duration; use anyhow::{anyhow, Result}; diff --git a/src/mqtt.rs b/src/mqtt.rs index 2ac1a5b..a8e155f 100644 --- a/src/mqtt.rs +++ b/src/mqtt.rs @@ -24,7 +24,7 @@ pub async fn create_client(config: &config::Config, machine_id: &str, availabili options.set_inflight(30); options.set_max_packet_size( - 30 * 1000 * 1000, // 30 MB + 30 * 1024 * 1024, // 30 MiB usize::MAX, ); diff --git a/src/util.rs b/src/util.rs index 8dfb92d..0e43cdd 100644 --- a/src/util.rs +++ b/src/util.rs @@ -18,13 +18,6 @@ pub fn spawn_nonessential(future: impl Future> + Send + 'stati }) } -#[inline] -pub fn run_nonessential(block: impl FnOnce() -> Result<()>) { - if let Err(error) = block() { - log_error(error); - } -} - #[inline] pub fn log_error(error: anyhow::Error) { log::error!("{:#}", error);