Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
Fetching contributors…

Cannot retrieve contributors at this time

executable file 23 lines (17 sloc) 0.469 kB
flname="/tmp/goldratio"
function filter {
echo $(cat $1|grep "<td width=\"68\" align=\"center\">"|head -n1|sed "s/<\/td>.*//"|sed "s/<td .*>//"|sed "s/[ \t]*//")
}
oldrate=$(filter "$flname.bak")
newrate=$(filter $flname)
ts=$(date +%s)
if [ $((ts % 15)) -eq 0 ]; then
wget --quiet http://66.38.218.33/market/ -O $flname &
fi
if [ ${#newrate} -eq 0 ]; then
rate=$oldrate
else
rate=$newrate
cp $flname "$flname.bak"
fi
echo "GOLD: <fc=#996600>$rate</fc>"
Jump to Line
Something went wrong with that request. Please try again.