summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2021-01-18 05:34:25 +0000
committerjao <jao@gnu.org>2021-01-18 05:34:25 +0000
commit5d105cde6fab854c465e1ce47709aca9971b66cb (patch)
tree79f91590f79729d01d9aac6754130de142f38be3
parentc057d1ec79240812422817aeed2c970bbb4f10b5 (diff)
downloadxmobar-config-5d105cde6fab854c465e1ce47709aca9971b66cb.tar.gz
xmobar-config-5d105cde6fab854c465e1ce47709aca9971b66cb.tar.bz2
tweaks
-rw-r--r--src/TopC.hs17
-rw-r--r--src/lib/Monitors.hs6
2 files changed, 13 insertions, 10 deletions
diff --git a/src/TopC.hs b/src/TopC.hs
index fabbacf..46d45bc 100644
--- a/src/TopC.hs
+++ b/src/TopC.hs
@@ -15,8 +15,9 @@ topProcL p = TopProc (p <~> ["-t"
diskIOL p = DiskIO [("/", "<totalbipat>"), ("/home", "<totalbipat>")]
(diskArgs p) 10
-mpd a p t =
- MPDX [ "-W", "12", "-b", "░", "-f", "▒", "-t", t, "--", "-p", p] 20 a
+mpd a p t i =
+ MPDX [ "-W", "12", "-b", "░", "-f", "▒", "-t", t
+ , "--", "-p", p, "-P", fni "\xf144", "-Z", i, "-S", i] 20 a
autoMPD light = AutoMPD [ "-T", "110", "-E", "…", "-W", "10", "-t" ,
@@ -38,11 +39,13 @@ musicMPRIS p = mpris p mprisName 180
-- music light = toggleMonitor "/tmp/mpris.st" musicPipe (pollMPD light)
-- music p = toggleMonitor "/tmp/mpris.st" (pollMPD (pIsLight p)) (musicMPRIS p)
-- music port = pollMPD port . pIsLight
-music = concatMonitor (fni " \xf1bc ")
- (mpd "mpd" "6600" "<remaining>")
- (mpd "mopidy" "6669" "<ppos>/<plength> <remaining>")
+music = concatMonitor " "
+ (mpd "mpd" "6600" "<statei> <remaining>" (fni "\xf001"))
+ (mpd "mopidy" "6669" "<statei> <ppos>/<plength> <remaining>"
+ (fni "\xf1bc"))
+
-- "https://wttr.in?format=" ++ fnn 3 "%c" ++ "+%t+%C+%w++" ++ fnn 1 "%m"
-wttrURL = "https://wttr.in?format=" ++ fnn 2 "+%m+" ++ "+%t+%C+" ++ fn 5 "%w"
+wttrURL = "https://wttr.in?format=" ++ fnn 2 "+%c+" ++ "+%t+%C+" ++ fn 5 "%w"
where fnn n x = urlEncode ("<fn=" ++ show n ++ ">") ++ x ++ urlEncode "</fn>"
encode c
| c == ' ' = "+"
@@ -103,7 +106,7 @@ config p = (baseConfig p) {
++ "|laTime| "
} where dimi = fc (pDim p) . fni
m = music
- ma = dimi "\xf001" ++ " |" ++ alias m ++ "| "
+ ma = " |" ++ alias m ++ "| "
-- w = (weather' "<skyConditionS> <tempC>° <weather>" "EGPH" p)
main :: IO ()
diff --git a/src/lib/Monitors.hs b/src/lib/Monitors.hs
index d4c5b17..adc0ae9 100644
--- a/src/lib/Monitors.hs
+++ b/src/lib/Monitors.hs
@@ -197,9 +197,9 @@ brightness' = Brightness ["--", "-D", "amdgpu_bl0", "-C", "brightness"] 10
memory = Memory ["-t","<available> M", "-p", "2", "-W", "7"] 20
-netdev name =
- Network name ["-t", "<up>", "-x", "", "--", "--up", fni "\xf0e8 "] 20 -- fn 2 "🔐 "
-proton0 = netdev "proton0"
+netdev name icon =
+ Network name ["-t", "<up>", "-x", "", "--", "--up", icon] 20 -- fn 2 "🔐 "
+proton0 = netdev "proton0" $ fn 2 "🔒 " -- fni "\xf0e8 "
laTime = DateZone "%H" "en_US" "US/Pacific" "laTime" 10
localTime = Date "%R" "datetime" 10