diff options
Diffstat (limited to 'pkgs/by-name/mp/mpdpopm/src/config.rs')
| -rw-r--r-- | pkgs/by-name/mp/mpdpopm/src/config.rs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/pkgs/by-name/mp/mpdpopm/src/config.rs b/pkgs/by-name/mp/mpdpopm/src/config.rs index 13a1891b..8bb5abfb 100644 --- a/pkgs/by-name/mp/mpdpopm/src/config.rs +++ b/pkgs/by-name/mp/mpdpopm/src/config.rs @@ -116,6 +116,17 @@ mod test_connection { } } +/// THe possible start-up mode. +#[derive(Default, Deserialize, Debug, Serialize)] +pub enum Mode { + #[default] + /// Don't do anything special + Normal, + + /// Already start the DJ mode on start-up + Dj, +} + /// This is the most recent `mppopmd` configuration struct. #[derive(Deserialize, Debug, Serialize)] #[serde(default)] @@ -133,6 +144,9 @@ pub struct Config { /// How to connect to mpd pub conn: Connection, + /// The mode to start in + pub mode: Mode, + /// The `mpd' root music directory, relative to the host on which *this* daemon is running pub local_music_dir: PathBuf, @@ -159,6 +173,7 @@ impl Config { local_music_dir: [PREFIX, "Music"].iter().collect(), played_thresh: 0.6, poll_interval_ms: 5000, + mode: Mode::default(), }) } } |
