From b5c1aef849c04dfcb5d670a6ba2db6bb9581af22 Mon Sep 17 00:00:00 2001 From: Alexander Epaneshnikov Date: Sun, 26 Apr 2020 19:26:46 +0300 Subject: [PATCH] add systemd unit --- autostart/systemd/espeakup.conf | 1 + autostart/systemd/espeakup.service | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 autostart/systemd/espeakup.conf create mode 100644 autostart/systemd/espeakup.service diff --git a/autostart/systemd/espeakup.conf b/autostart/systemd/espeakup.conf new file mode 100644 index 0000000..56aebc1 --- /dev/null +++ b/autostart/systemd/espeakup.conf @@ -0,0 +1 @@ +default_voice= diff --git a/autostart/systemd/espeakup.service b/autostart/systemd/espeakup.service new file mode 100644 index 0000000..85c1f55 --- /dev/null +++ b/autostart/systemd/espeakup.service @@ -0,0 +1,16 @@ +[Unit] +Description=Software speech output for Speakup +# espeakup needs to start after the audio devices appear, hopefully this should go away in the future +Wants=systemd-udev-settle.service +After=systemd-udev-settle.service sound.target + +[Service] +Type=forking +EnvironmentFile=/etc/conf.d/espeakup +PIDFile=/run/espeakup.pid +ExecStart=/usr/bin/espeakup --default-voice=${default_voice} +ExecReload=/bin/kill -HUP $MAINPID +Restart=always + +[Install] +WantedBy=sound.target