feat: refactor + qol
This commit is contained in:
parent
a8847b93cf
commit
7870f584a8
7 changed files with 277 additions and 173 deletions
|
@ -2,7 +2,7 @@ mod listeners;
|
|||
mod manager;
|
||||
mod socket;
|
||||
|
||||
use anyhow::Result;
|
||||
use anyhow::{Context, Result};
|
||||
|
||||
fn main() -> Result<()> {
|
||||
// let systemd know we're ready
|
||||
|
@ -20,6 +20,11 @@ fn main() -> Result<()> {
|
|||
let (ipc_tx, ipc_rx) = smol::channel::unbounded();
|
||||
smol::spawn(listeners::ipc_listener(ipc_tx)).detach();
|
||||
// begin managing niri tags
|
||||
let niri_tag = manager::NiriTag::new();
|
||||
smol::block_on(niri_tag.manage_tags(event_rx, ipc_rx))
|
||||
smol::block_on(async {
|
||||
let niri_tag = manager::NiriTag::new()
|
||||
.await
|
||||
.context("Initialising niri tag manager")
|
||||
.unwrap();
|
||||
niri_tag.manage_tags(event_rx, ipc_rx).await
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue