aboutsummaryrefslogtreecommitdiff
path: root/scripts/notify-saved-name.sh
blob: c8ca399e68aa73ca1e9664f0b23c65d301d5efb4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

[ "$GSR_SHOW_SAVED_NOTIFICATION" != "1" ] && exit 0

filepath="$1"
type="$2"

file_name="$(basename "$filepath")"

case "$type" in
    "regular")
        gsr-notify --text "Saved recording to '$file_name'" --timeout 3.0 --icon record --bg-color "$GSR_NOTIFY_BG_COLOR"
        ;;
    "replay")
        gsr-notify --text "Saved replay to '$file_name'" --timeout 3.0 --icon replay --bg-color "$GSR_NOTIFY_BG_COLOR"
        ;;
esac