diff options
author | Andrea Rossato <andrea.rossato@ing.unitn.it> | 2007-07-08 12:10:33 +0200 |
---|---|---|
committer | Andrea Rossato <andrea.rossato@ing.unitn.it> | 2007-07-08 12:10:33 +0200 |
commit | 39820c0004230f4df7e256bc83ec1c9578f94a8d (patch) | |
tree | de263f0d05be28e81d2acb90cfb7a6ab589f93b9 /Monitors/Weather.hs | |
parent | c88df2b5d3cabc8e8171a422a48d0f811549f512 (diff) | |
download | xmobar-39820c0004230f4df7e256bc83ec1c9578f94a8d.tar.gz xmobar-39820c0004230f4df7e256bc83ec1c9578f94a8d.tar.bz2 |
monitors are now run internally
darcs-hash:20070708101033-d6583-495a895544a1fc84d4d69f52a7f26dd42b6c8af4.gz
Diffstat (limited to 'Monitors/Weather.hs')
-rw-r--r-- | Monitors/Weather.hs | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/Monitors/Weather.hs b/Monitors/Weather.hs index 2d957bd..63eb48e 100644 --- a/Monitors/Weather.hs +++ b/Monitors/Weather.hs @@ -12,7 +12,7 @@ -- ----------------------------------------------------------------------------- -module Main where +module Monitors.Weather where import Monitors.Common @@ -25,8 +25,8 @@ import System.IO import Text.ParserCombinators.Parsec -monitorConfig :: IO MConfig -monitorConfig = +weatherConfig :: IO MConfig +weatherConfig = do lc <- newIORef "#BFBFBF" l <- newIORef 15 nc <- newIORef "#00FF00" @@ -53,8 +53,7 @@ monitorConfig = ] return $ MC nc l lc h hc t p u a e - -data WeatherInfo = +data WeatherInfo = WI { stationPlace :: String , stationState :: String , year :: String @@ -70,8 +69,6 @@ data WeatherInfo = , pressure :: String } deriving (Show) - - pTime :: Parser (String, String, String, String) pTime = do y <- getNumbersAsString char '.' @@ -147,7 +144,9 @@ runWeather str = package :: String package = "xmb-weather" +{- main :: IO () main = do let af = return "No station ID specified" - runMonitor monitorConfig af runWeather + runMonitor weatherConfig af runWeather +-}
\ No newline at end of file |