flake + ci rework

This commit is contained in:
Robin Appelman 2025-06-09 17:07:18 +02:00
commit 6e13b8e412
10 changed files with 178 additions and 165 deletions

View file

@ -1,5 +1,6 @@
use std::path::PathBuf;
use futures::{pin_mut, StreamExt};
use std::pin::pin;
use tokio_stream::StreamExt;
use glob::GlobError;
use evdev_shortcut::{Key, Modifier, Shortcut, ShortcutListener};
@ -11,9 +12,7 @@ async fn main() {
let devices =
glob::glob("/dev/input/by-id/*-kbd").unwrap().collect::<Result<Vec<PathBuf>, GlobError>>().unwrap();
let stream = listener.listen(&devices).unwrap();
pin_mut!(stream);
let mut stream = pin!(listener.listen(&devices).unwrap());
while let Some(event) = stream.next().await {
println!("{} {}", event.shortcut, event.state);