View Single Post
Alexxxl's Avatar
Posts: 152 | Thanked: 91 times | Joined on Mar 2013 @ Russia Saratov
#135
Meecast

Code:
#!/bin/bash

source /tmp/session_bus_address.user
while true
do


echo "$(qdbus com.meecast.data /com/meecast/data com.meecast.data.GetCurrentWeather)" > /usr/share/meecast.txt
a=$(sed '1!d' /usr/share/meecast.txt)

b=$(sed '2!d' /usr/share/meecast.txt)
c=$(sed '6!d' /usr/share/meecast.txt)
d=$(sed '8!d' /usr/share/meecast.txt)

# echo $a $b $c $d

qdbus com.mikeasoft.rockwatch /rockwatch showSMS "Meecast" "$a ,       ""$b В°C, ""$c,        ""$d"


sleep 7200 
# 2 hours
done

Last edited by Alexxxl; 2013-12-23 at 10:24.