Create IPC socket on UNIX platforms (#1018)
* Create IPC socket on UNIX platforms Creates an IPC socket which remote programs/scripts can connect to. This can be used to control ncspot or fetch the current playback status. At the moment, only remote control is implemented. Next step is to send the current player status as a JSON object. Fixes #524 * Publish status changes to connected sockets Whenever the playback mode (playing, paused, stopped) or the track changes, all socket listeners will be notified. Fixes #924, fixes #1019 * Document IPC feature
This commit is contained in:
committed by
GitHub
parent
93816af654
commit
ec4b7c209a
@@ -32,7 +32,7 @@ use crate::ASYNC_RUNTIME;
|
||||
|
||||
pub const VOLUME_PERCENT: u16 = ((u16::max_value() as f64) * 1.0 / 100.0) as u16;
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq, Serialize)]
|
||||
pub enum PlayerEvent {
|
||||
Playing(SystemTime),
|
||||
Paused(Duration),
|
||||
|
||||
Reference in New Issue
Block a user