Cuckoo clock in bash

Because why not….

Script:

#!/bin/bash
num_cuckoo=$(date +%l)
startsample="/path/to/cuckoo_start.flac"
cuckoosample="/path/to/clock/cuckoo.flac"

play -V0 $startsample
COUNTER=0
while [  $COUNTER -lt $num_cuckoo ]; do
        play -V0 $cuckoosample
        let COUNTER=COUNTER+1
done

Files:

Crontab:

0 * * * * /path/to/script

Legg igjen en kommentar

Din e-postadresse vil ikke bli publisert. Obligatoriske felt er merket med *