diff options
author | Christian Hesse <mail@eworm.de> | 2015-10-12 14:50:12 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2015-10-12 14:50:12 +0200 |
commit | 69c8a3a0546d16b9c965641a76f8fc2499e8de0b (patch) | |
tree | 589d2c18582166f5891a98f1bb8f748bd847952a | |
parent | 6acd5f4e469aa043298db4235edc77a4db24bfaf (diff) | |
download | netlink-notify-69c8a3a0546d16b9c965641a76f8fc2499e8de0b.tar.gz netlink-notify-69c8a3a0546d16b9c965641a76f8fc2499e8de0b.tar.zst |
use systemd user unit to (auto-)start
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | README.md | 8 | ||||
-rw-r--r-- | netlink-notify.desktop | 8 | ||||
-rw-r--r-- | systemd/netlink-notify.service | 9 |
4 files changed, 14 insertions, 13 deletions
@@ -46,7 +46,7 @@ install: install-bin install-doc install-bin: netlink-notify icons $(INSTALL) -D -m0755 netlink-notify $(DESTDIR)/usr/bin/netlink-notify - $(INSTALL) -D -m0644 netlink-notify.desktop $(DESTDIR)/etc/xdg/autostart/netlink-notify.desktop + $(INSTALL) -D -m0644 systemd/netlink-notify.service $(DESTDIR)/usr/lib/systemd/user/netlink-notify.service $(INSTALL) -D -m0755 icons/netlink-notify-up.svg $(DESTDIR)/usr/share/icons/hicolor/scalable/status/netlink-notify-up.svg $(INSTALL) -D -m0755 icons/netlink-notify-down.svg $(DESTDIR)/usr/share/icons/hicolor/scalable/status/netlink-notify-down.svg $(INSTALL) -D -m0755 icons/netlink-notify-address.svg $(DESTDIR)/usr/share/icons/hicolor/scalable/status/netlink-notify-address.svg @@ -52,14 +52,14 @@ followed by: This will place an executable at `/usr/bin/netlink-notify`, documentation can be found in `/usr/share/doc/netlink-notify/`. -Additionally a desktop file is installed to `/etc/xdg/autostart/`, this -automatically starts the program when logged in to a desktop environment. +Additionally a systemd unit file is installed to `/usr/lib/systemd/user/`. Usage ----- -Just run `netlink-notify` after installation or re-login to desktop -environment for autostart. +Just run `netlink-notify` to run it once. A systemd user service can be +started and/or enabled with `systemctl --user start netlink-notify` +or `systemctl --user enable netlink-notify`. ### Upstream diff --git a/netlink-notify.desktop b/netlink-notify.desktop deleted file mode 100644 index 6b8e10b..0000000 --- a/netlink-notify.desktop +++ /dev/null @@ -1,8 +0,0 @@ -[Desktop Entry] -Name=Netlink Notify -Icon=network-transmit-receive -Exec=/usr/bin/netlink-notify -Terminal=false -Type=Application -StartupNotify=false -Categories=Utility diff --git a/systemd/netlink-notify.service b/systemd/netlink-notify.service new file mode 100644 index 0000000..2db23c7 --- /dev/null +++ b/systemd/netlink-notify.service @@ -0,0 +1,9 @@ +[Unit] +Description=Netlink Notification + +[Service] +Type=simple +ExecStart=/usr/bin/netlink-notify + +[Install] +WantedBy=default.target |