fix: correctly omit --icon from notify-send when not set
This commit is contained in:
parent
452eee9454
commit
0e4ed6b3c5
2 changed files with 4 additions and 4 deletions
|
@ -59,12 +59,12 @@ function _auto_notify_message() {
|
|||
transient=""
|
||||
icon=${AUTO_NOTIFY_ICON_FAILURE:-""}
|
||||
fi
|
||||
local icon_arg=""
|
||||
if [[ -n "$icon" ]]; then
|
||||
icon_arg="--icon=$icon"
|
||||
notify-send "$title" "$body" --app-name=zsh $transient "--urgency=$urgency" "--expire-time=$AUTO_NOTIFY_EXPIRE_TIME" "--icon=$icon"
|
||||
else
|
||||
notify-send "$title" "$body" --app-name=zsh $transient "--urgency=$urgency" "--expire-time=$AUTO_NOTIFY_EXPIRE_TIME"
|
||||
fi
|
||||
|
||||
notify-send "$title" "$body" --app-name=zsh $transient "--urgency=$urgency" "--expire-time=$AUTO_NOTIFY_EXPIRE_TIME" "$icon_arg"
|
||||
elif [[ "$platform" == "Darwin" ]]; then
|
||||
osascript \
|
||||
-e 'on run argv' \
|
||||
|
|
Loading…
Add table
Reference in a new issue