From 4075554aa89dc6f67dfcbd6b0b07d990b21a6662 Mon Sep 17 00:00:00 2001 From: Tomasz Kramkowski Date: Wed, 4 Sep 2024 20:38:59 +0100 Subject: Add a systemd service file This is helpful if you're stuck in a hole with nothing except for a laptop running Ubuntu to dig yourself out of it. --- battd.service | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 battd.service diff --git a/battd.service b/battd.service new file mode 100644 index 0000000..a6a3a5a --- /dev/null +++ b/battd.service @@ -0,0 +1,12 @@ +# expects: ./install /opt/battd +[Unit] +Description=Battery Daemon +Documentation=https://kramkow.ski/project/battd.html + +[Service] +WorkingDirectory=/opt/battd +ExecStart=/opt/battd/run +ExecReload=kill -HUP $MAINPID + +[Install] +WantedBy=multi-user.target -- cgit v1.2.3-54-g00ecf