dotwryn/bin/play-sound

23 lines
556 B
Plaintext
Raw Normal View History

2022-02-06 07:15:14 +00:00
#!/bin/zsh
source "$HOME/.config/wryn/env.zsh"
2020-10-09 23:07:16 +00:00
PLAY() {
2021-02-25 00:38:02 +00:00
eval "$MEDIA_ENGINE" "$SFX_PATH/$1"
2022-02-06 07:15:14 +00:00
true
2020-10-09 23:07:16 +00:00
}
case $1 in
volume ) PLAY yaru-message.oga ;;
mute ) PLAY smooth-dialog-warning.oga ;;
backlight ) PLAY yaru-audio-volume-change.oga ;;
login ) PLAY yaru-desktop-login.oga ;;
logout ) PLAY smooth-desktop-login.oga ;;
2020-11-17 22:11:42 +00:00
notify ) PLAY yaru-complete.oga ;;
undock ) PLAY yaru-desktop-login.oga ;;
homedock ) PLAY homedock.oga ;;
gamedock ) PLAY gamedock.oga ;;
2022-02-06 07:15:14 +00:00
* )
[ -f "$SFX_PATH/$1" ] && PLAY $1 || ls $SFX_PATH
;;
2020-10-09 23:07:16 +00:00
esac