blob: 53766116249e6b4e3fdb20f26e08ccf4236fda8d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
#! /bin/sh
set -euf
max=100
step=10
min=0
announce() {
# fade-out streams
for i in `seq $max -$step $min`; do
amixer -q -c 0 -D hw:0 sset Front $i%
sleep 0.1
done
/krebs/streams/streams stop
amixer -q -c 0 -D hw:0 sset Front $max%
mplayer /krebs/god/overlord/announce.mp3 >/dev/null
espeak -v de -s 120 -a 900 "$*"
# fade-in streams
/krebs/streams/streams start
for i in `seq $min $step $max`; do
sleep 0.1
amixer -q -c 0 -D hw:0 sset Front $i%
done
}
case "${1---help}" in
--help) echo "Make an announcement! Usage: /overlord <text>";;
*) announce "$@";;
esac
|