Trying to create a bash script to pick a random radio ip to make mplayer play:
#!/bin/sh
#A simple script to run random radio channels on mplayer
radio = (http://162.253.40.181:8808 http://195.154.69.121:8000 http://108.163.197.114:8103 http://216.245.201.73:9910 http://5.63.145.172:7090)
current = echo $[ 1 + $[ RANDOM % 5 ]]
#echo $current
mplayer $radio{[current]}
I think my array declaration is wrong because the script throws out the following error:
Syntax error: "(" unexpected