Skip to content

patch: notify-send script that gracefully ignores options and redirects to herbe#10

Open
cemkeylan wants to merge 1 commit intodudik:masterfrom
cemkeylan:notify
Open

patch: notify-send script that gracefully ignores options and redirects to herbe#10
cemkeylan wants to merge 1 commit intodudik:masterfrom
cemkeylan:notify

Conversation

@cemkeylan
Copy link
Copy Markdown

@cemkeylan cemkeylan commented Aug 28, 2020

Description

So many shell scripts call notify-send, and I have seen a lot of those use options in them. This script parses and ignores these options, and redirects the rest to herbe. It calls herbe async to replicate the behaviour of notify-send.

Download

notify-send

@dudik dudik changed the title Add notify-send script that gracefully ignores options and redirects to herbe patch: notify-send script that gracefully ignores options and redirects to herbe Sep 1, 2020
@dudik dudik added the patch This pull request is a patch label Sep 1, 2020
@tunjan
Copy link
Copy Markdown

tunjan commented Jun 16, 2021

Please someone help me how to use this script.

Just add that script to your $PATH

owm111 pushed a commit to owm111/herbe that referenced this pull request Jun 18, 2022
owm111 pushed a commit to owm111/herbe that referenced this pull request Jun 18, 2022
owm111 pushed a commit to owm111/herbe that referenced this pull request Jun 18, 2022
@lucaraymaekers
Copy link
Copy Markdown

Are you missing the --app-name option?

diff --git a/notify-send b/notify-send
old mode 100755
new mode 100644
index 3a3872b..edd76d5
--- a/notify-send
+++ b/notify-send
@@ -31,6 +31,11 @@ parse() {
         OPTARG=$2
         _=$OPTARG
         shift ;;
+      -a | --app-name)
+        [ $# -le 1 ] && set -- "$1" required && break
+        OPTARG=$2
+        _=$OPTARG
+        shift ;;
       -t | --expire-time)
         [ $# -le 1 ] && set -- "$1" required && break
         OPTARG=$

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

patch This pull request is a patch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants