diff --git a/espanso-detect/src/lib.rs b/espanso-detect/src/lib.rs index f12253d..3f8d85a 100644 --- a/espanso-detect/src/lib.rs +++ b/espanso-detect/src/lib.rs @@ -33,4 +33,4 @@ pub mod mac; #[cfg(target_os = "macos")] #[macro_use] -extern crate lazy_static; \ No newline at end of file +extern crate lazy_static; diff --git a/espanso-detect/src/mac/mod.rs b/espanso-detect/src/mac/mod.rs index bb88fdd..8137489 100644 --- a/espanso-detect/src/mac/mod.rs +++ b/espanso-detect/src/mac/mod.rs @@ -17,10 +17,13 @@ * along with espanso. If not, see . */ -use std::{ffi::{CStr}, sync::{ +use std::{ + ffi::CStr, + sync::{ mpsc::{channel, Receiver, Sender}, Arc, Mutex, - }}; + }, +}; use lazycell::LazyCell; use log::{error, trace, warn}; @@ -169,7 +172,8 @@ impl From for Option { let (key, variant) = key_code_to_key(raw.key_code); let value = if raw.buffer_len > 0 { - let raw_string_result = CStr::from_bytes_with_nul(&raw.buffer[..((raw.buffer_len + 1) as usize)]); + let raw_string_result = + CStr::from_bytes_with_nul(&raw.buffer[..((raw.buffer_len + 1) as usize)]); match raw_string_result { Ok(c_string) => { let string_result = c_string.to_str(); @@ -340,4 +344,3 @@ mod tests { ); } } - diff --git a/espanso/src/main.rs b/espanso/src/main.rs index 374364a..65a4bc7 100644 --- a/espanso/src/main.rs +++ b/espanso/src/main.rs @@ -1,5 +1,5 @@ use espanso_detect::event::{InputEvent, Status}; -use espanso_inject::{Injector, get_injector}; +use espanso_inject::{get_injector, Injector}; use espanso_ui::{event::UIEvent::*, icons::TrayIcon, menu::*}; use simplelog::{CombinedLogger, Config, LevelFilter, TermLogger, TerminalMode};