diff --git a/xmobar-bottom.hs b/xmobar-bottom.hs
deleted file mode 100644
index f262ab2..0000000
--- a/xmobar-bottom.hs
+++ /dev/null
@@ -1,24 +0,0 @@
-import Xmobar
-
-config :: Config
-config =
- defaultConfig
- { font = "Terminus 8",
- textOffset = 0,
- bgColor = "#121212",
- fgColor = "#cccccc",
- position = Bottom,
- template = " %disk-root% | %disk-home% | %status-redshift% | %status-udiskie% }{ %now-playing% | %volume% ",
- commands =
- [ Run XMonadLog,
- Run $ Com "monitors" ["disk", "/"] "disk-root" 35000,
- Run $ Com "monitors" ["disk", "/home"] "disk-home" 35000,
- Run $ Com "monitors" ["service", "redshift"] "status-redshift" 6000,
- Run $ Com "monitors" ["service", "udiskie"] "status-udiskie" 6000,
- Run $ PipeReader "/tmp/pipe-now-playing" "now-playing",
- Run $ PipeReader "/tmp/pipe-volume" "volume"
- ]
- }
-
-main :: IO ()
-main = xmobar config
diff --git a/xmobar-top.hs b/xmobar.hs
similarity index 73%
rename from xmobar-top.hs
rename to xmobar.hs
index 885c8ce..88a697b 100644
--- a/xmobar-top.hs
+++ b/xmobar.hs
@@ -8,13 +8,14 @@ config =
bgColor = "#121212",
fgColor = "#cccccc",
position = Top,
- template = " %XMonadLog% }{ \61381 %memory% | %load% | \62153 %cpu% | %battery% | %date% ",
+ template = " %XMonadLog% }{ %volume% | %load% | %battery% | %date% ",
commands =
[ Run XMonadLog,
Run $ Com "monitors" ["battery"] "battery" 1200,
Run $ Com "monitors" ["cpu"] "cpu" 100,
Run $ Com "monitors" ["memory"] "memory" 100,
Run $ Com "monitors" ["load"] "load" 100,
+ Run $ PipeReader "/tmp/pipe-volume" "volume",
Run $ Date "%m/%d/%Y %-I:%M %p" "date" 600
]
}
diff --git a/xmonad-frosty.cabal b/xmonad-frosty.cabal
index 5a3b5e9..fa9a55c 100644
--- a/xmonad-frosty.cabal
+++ b/xmonad-frosty.cabal
@@ -16,6 +16,19 @@ executable xmonad
default-language: GHC2021
default-extensions: ImportQualifiedPost
+executable xmobar
+ main-is: xmobar.hs
+ ghc-options:
+ -O2 -Wall -Wcompat -Wincomplete-record-updates
+ -Wredundant-constraints -rtsopts -threaded -with-rtsopts=-N
+
+ build-depends:
+ , base
+ , xmobar >=0.48
+
+ default-language: GHC2021
+ default-extensions: ImportQualifiedPost
+
executable xmobar-top
main-is: xmobar-top.hs
ghc-options:
diff --git a/xmonad.hs b/xmonad.hs
index c91b2a1..77ab197 100644
--- a/xmonad.hs
+++ b/xmonad.hs
@@ -26,8 +26,7 @@ import XMonad.Util.NamedScratchpad
main :: IO ()
main =
xmonad
- . withSB (statusBarProp "xmobar-bottom" $ pure myPP)
- . withSB (statusBarProp "xmobar-top" $ pure myPP)
+ . withSB (statusBarProp "xmobar" $ pure myPP)
. toggleFullFloatEwmhFullscreen
. ewmhFullscreen
. ewmh