import Xmobar import Config import Monitors import Music (mpris, gpmd, mpdt) memoratio = Memory ["-t","%", "-p", "2", "-W", "3"] 20 topProcL p = TopProc (p <~> ["-t" , " " ++ " · " , "-w", "12", "-L" , "10", "-H", "80"]) 15 diskIOL p = DiskIO [("/", ""), ("/home", "")] (diskArgs p) 10 mpd a p t i = MPDX [ "-W", "12", "-b", "░", "-f", "▒", "-t", t , "--", "-p", p, "-P", fni "\xf144", "-Z", i, "-S", i] 20 a music = concatMonitor " " m ms where m = mpd "mpd" "6600" " " icm ms = mpd "mopidy" "6669" " / " ics icm = fni "\xf001" ics = fni "\xf1bc" config p = (baseConfig p) { position = TopSize C 100 (defaultHeight - 1) , textOffset = defaultHeight - 8 , textOffsets = [defaultHeight - 9, defaultHeight - 9, defaultHeight - 6, defaultHeight - 8, defaultHeight - 8, defaultHeight - 8] , border = FullB , commands = [ Run (topProcL p) , Run m , Run (thinkTemp p) , Run (NamedXPropertyLog "_EMACS_LOG" "elog") , Run (cpuBars p) , Run memoratio , Run (diskU p) , Run (diskIOL p) , Run brightness' , Run (kbd p) , Run (iconBatt p) , Run (wireless p "wlp1s0") , Run (dynNetwork p) , Run proton0 , Run (masterVol p) , Run captureVol , Run laTime , Run localTime , Run w -- LEGE, LEBL, KCV0 ] , template = " " ++ "|batt0| " ++ dimi "\xf26c" ++ " |bright| " ++ " |proton0||wlp1s0wi|" ++ " |dynnetwork| " ++ "" ++ " |default:Master| " ++ dimi "\xf130" ++ " |default:Capture|" ++ " " ++ ma ++ " |EGPH| " ++ " {} " ++ fc (pHigh p) "|elog|" ++ "|kbd| " ++ "|multicpu| " ++ "|multicoretemp| " ++ " |top| " ++ " " ++ fni "\xf0c9" ++ " |memory| " ++ " |diskio| |disku| " ++ " |datetime| " ++ "|laTime| " } where dimi = fc (pDim p) . fni m = music ma = " |" ++ alias m ++ "| " w = (weather' " ° " "EGPH" p) main :: IO () main = palette >>= configFromArgs . config >>= xmobar