diff options
author | Krzysztof Kosciuszkiewicz <k.kosciuszkiewicz@gmail.com> | 2007-07-10 16:08:45 +0200 |
---|---|---|
committer | Krzysztof Kosciuszkiewicz <k.kosciuszkiewicz@gmail.com> | 2007-07-10 16:08:45 +0200 |
commit | 528556a36d5ff686689568c61422143276b0dc96 (patch) | |
tree | 80d00a09a14146373d20759961bca381771af580 /Monitors/Batt.hs | |
parent | 8453821a99a4a211b2c489f1a90fa1ecea8a690d (diff) | |
download | xmobar-528556a36d5ff686689568c61422143276b0dc96.tar.gz xmobar-528556a36d5ff686689568c61422143276b0dc96.tar.bz2 |
Clean up default options for monitors.
* Moved default configuration to Monitors.Common
* Colors are optional and are off by default
darcs-hash:20070710140845-ba08c-86afb9d30e4b71ad48539510feabde650b1b6045.gz
Diffstat (limited to 'Monitors/Batt.hs')
-rw-r--r-- | Monitors/Batt.hs | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/Monitors/Batt.hs b/Monitors/Batt.hs index b3890c8..fcc78fd 100644 --- a/Monitors/Batt.hs +++ b/Monitors/Batt.hs @@ -14,25 +14,18 @@ module Monitors.Batt where -import Data.IORef import qualified Data.ByteString.Lazy.Char8 as B import System.Posix.Files import Monitors.Common battConfig :: IO MConfig -battConfig = - do lc <- newIORef "#FF0000" - l <- newIORef 25 - nc <- newIORef "#FF0000" - h <- newIORef 75 - hc <- newIORef "#00FF00" - t <- newIORef "Batt: <left>" - p <- newIORef package - u <- newIORef "" - a <- newIORef [] - e <- newIORef ["left"] - return $ MC nc l lc h hc t p u a e +battConfig = newConfig + "Batt: <left>" -- template + package -- package + "" -- usage tail? + [] -- added args + ["left"] -- available replacements fileB1 :: (String, String) fileB1 = ("/proc/acpi/battery/BAT1/info", "/proc/acpi/battery/BAT1/state") @@ -84,4 +77,4 @@ main :: IO () main = do let af = runBatt [] runMonitor battConfig af runBatt --}
\ No newline at end of file +-} |