diff options
author | jao <jao@gnu.org> | 2019-06-29 23:26:53 +0100 |
---|---|---|
committer | jao <jao@gnu.org> | 2019-06-29 23:26:53 +0100 |
commit | 7f6b57d43ae52cb8cb5a99eb40c092c1442a9c21 (patch) | |
tree | dd0444bd39a4f006d2f365e53273e86bf288b8fe | |
parent | b0030f6c35a1ab02bc4ff256984c75513981cd8f (diff) | |
download | xmobar-config-7f6b57d43ae52cb8cb5a99eb40c092c1442a9c21.tar.gz xmobar-config-7f6b57d43ae52cb8cb5a99eb40c092c1442a9c21.tar.bz2 |
New WeatherX
-rw-r--r-- | src/lib/Bottom.hs | 2 | ||||
-rw-r--r-- | src/lib/Monitors.hs | 37 |
2 files changed, 27 insertions, 12 deletions
diff --git a/src/lib/Bottom.hs b/src/lib/Bottom.hs index 8fb7fe6..00cc868 100644 --- a/src/lib/Bottom.hs +++ b/src/lib/Bottom.hs @@ -16,7 +16,7 @@ config cs tpl p = (baseConfig p) { \ <action=`toggle-pasystray.sh `><fn=2>🎧</fn>|default:Master|\ \ |default:Capture|</action> <fn=2>🎵</fn>" ++ tpl - ++ " {} |mbox| <fn=2>🌤</fn> |EGPH| \ + ++ " {} |mbox| |EGPH| \ \ <fn=2>⏰ </fn>|uptime| <fn=2>🕓 </fn>|datetime| |laTime| " , commands = [ Run (uptime p) , Run (wireless p) diff --git a/src/lib/Monitors.hs b/src/lib/Monitors.hs index 1ad3c89..f3e76f1 100644 --- a/src/lib/Monitors.hs +++ b/src/lib/Monitors.hs @@ -61,20 +61,35 @@ uptime p = Uptime (p <~> [ "-t" , "<days> <hours>", "-m", "3", "-c", "0", "-S" , "On" , "-L", "10", "-H", "100"]) 600 weather st = - Weather st ["-t", "<tempC>° <rh>% <windKmh> <skyCondition> (<hour>)" - , "-L","10", "-H", "25", "--normal", "black", - "--high", "lightgoldenrod4", "--low", "darkseagreen4"] 18000 + WeatherX st + [ ("clear", "🌣") + , ("sunny", "🌣") + , ("mostly clear", "🌤") + , ("mostly sunny", "🌤") + , ("partly sunny", "⛅") + , ("fair", "🌑") + , ("cloudy","☁") + , ("overcast","☁") + , ("partly cloudy", "⛅") + , ("mostly cloudy", "🌧") + , ("considerable cloudiness", "⛈")] + ["-t", "<fn=2><skyConditionS></fn> <tempC>° <rh>% <windKmh> (<hour>)" + , "-L","10", "-H", "25", "--normal", "black" + , "--high", "lightgoldenrod4", "--low", "darkseagreen4"] + 18000 batt p = BatteryN ["BAT0"] - ((p <~> ["-t", "<acstatus> <left>%" - , "-S", "Off", "-d", "0", "-m", "3" - , "-L", "10", "-H", "80", "-p", "3"]) - ++ [ "--" - , "-i", "<fn=2>🔌</fn>", "-O", " <fn=2>🔌</fn> <timeleft> <watts>" - , "-o", " <fn=2>🔋</fn> <timeleft> <watts>" - , "-H", "16", "-L", "10" - , "-h", "sienna4", "-l", "gray20"]) 50 "batt0" + ["-t", "<acstatus> <left>%" + , "-S", "Off", "-d", "0", "-m", "3" + , "-L", "10", "-H", "90", "-p", "3" + , "--low", (pHigh p), "--normal", (pNormal p), "--high", (pLow p) + , "--" + , "-i", "<fn=2>🔌</fn>" + , "-O", " <fn=2>🔌</fn> <timeleft> <watts>" + , "-o", " <fn=2>🔋</fn> <timeleft> <watts>" + , "-H", "16", "-L", "10" + , "-h", "sienna4", "-l", "gray20"] 50 "batt0" coreTemp p = CoreTemp (p <~> ["-t", "<core1>° <core2>°" |