~proycon/dotfiles

dotfiles/sxmo/hooks/ring -rwxr-xr-x 446 bytes
cbcaa231Maarten van Gompel added network-down and renamed the other a month ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env sh

# This script is executed (asynchronously) when you get an incoming call
# You can use it to play a ring tone


# Start the mpv ring until another hook kill it
mpv --quiet --no-video --loop /usr/share/sxmo/ring.ogg &
MPVID=$!
echo "$MPVID" > "$XDG_RUNTIME_DIR/sxmo.ring.pid"

~/dotfiles/notifysend.sh notify/proycon/phone "$1" &

# Vibrate while mpv is running
while kill -0 $MPVID; do
		sxmo_vibratepine 1500
		sleep 0.5
done