From d0396c4916cc5b70ce1b4cdad4e742d9d372c6e5 Mon Sep 17 00:00:00 2001 From: baduhai Date: Mon, 23 Aug 2021 21:26:51 +0200 Subject: [PATCH] Added notification app title. --- main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.py b/main.py index d612e31..8366c86 100644 --- a/main.py +++ b/main.py @@ -57,11 +57,11 @@ def get_picture(appid): def send_notification(message): m = json.loads(message) if m['priority'] <= 3: - subprocess.Popen(['notify-send', m['title'], m['message'], "-u", "low", "-i", get_picture(m['appid'])]) + subprocess.Popen(['notify-send', m['title'], m['message'], "-u", "low", "-i", get_picture(m['appid']), "-a", "Gotify"]) if 4 <= m['priority'] <= 7: - subprocess.Popen(['notify-send', m['title'], m['message'], "-u", "normal", "-i", get_picture(m['appid'])]) + subprocess.Popen(['notify-send', m['title'], m['message'], "-u", "normal", "-i", get_picture(m['appid']), "-a", "Gotify"]) if m['priority'] > 7: - subprocess.Popen(['notify-send', m['title'], m['message'], "-u", "critical", "-i", get_picture(m['appid'])]) + subprocess.Popen(['notify-send', m['title'], m['message'], "-u", "critical", "-i", get_picture(m['appid']), "-a", "Gotify"]) def on_message(ws, message): print(message)