mirror of
https://github.com/Zedfrigg/ironbar.git
synced 2025-08-17 14:51:04 +02:00
refactor: update to rust 2024, fix strict clippy warnings
This commit is contained in:
parent
79c917857c
commit
202c19efd4
57 changed files with 132 additions and 124 deletions
|
@ -9,7 +9,7 @@ use tracing_appender::rolling::Rotation;
|
|||
use tracing_error::ErrorLayer;
|
||||
use tracing_subscriber::fmt::{Layer, MakeWriter};
|
||||
use tracing_subscriber::prelude::*;
|
||||
use tracing_subscriber::{fmt, EnvFilter};
|
||||
use tracing_subscriber::{EnvFilter, fmt};
|
||||
|
||||
struct MakeFileWriter {
|
||||
file_writer: NonBlocking,
|
||||
|
@ -32,7 +32,11 @@ impl<'a> MakeWriter<'a> for MakeFileWriter {
|
|||
pub fn install_logging() -> Result<WorkerGuard> {
|
||||
// Disable backtraces by default
|
||||
if env::var("RUST_LIB_BACKTRACE").is_err() {
|
||||
env::set_var("RUST_LIB_BACKTRACE", "0");
|
||||
// as this is the very first thing we do (before runtimes are set up)
|
||||
// we can be sure that it only runs in a single-thread context
|
||||
unsafe {
|
||||
env::set_var("RUST_LIB_BACKTRACE", "0");
|
||||
}
|
||||
}
|
||||
|
||||
// keep guard in scope
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue