Compare commits
4
Commits
9cb98bef22
...
3e77c8be34
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3e77c8be34
|
||
|
|
fbd2312eee
|
||
|
|
a858e92b50
|
||
|
|
ba720116a6
|
No files matched your search
@@ -5,7 +5,7 @@
|
||||
# run and isn't STALE. The bar names the model when it isn't IFS, and adds a red "!" when it is stale.
|
||||
# AIFS/AIGEFS are left out: AIFS comes through the same ECMWF pipeline as IFS and fails with it.
|
||||
|
||||
MODELS=(ecmwf_ifs025 ncep_gefs025 icon_seamless_eps google_weathernext2_ensemble)
|
||||
MODELS=(ecmwf_ifs025 icon_seamless_eps ncep_gefs025 google_weathernext2_ensemble)
|
||||
declare -A LABEL=([ncep_gefs025]=GEFS [icon_seamless_eps]=ICON [google_weathernext2_ensemble]=Google)
|
||||
|
||||
# pick DAYS: sets $line (the --brief output) and $model. IFS unless it is STALE; a fallback only if its
|
||||
|
||||
+22
-10
@@ -35,7 +35,8 @@ main =
|
||||
. ewmhFullscreen
|
||||
. setEwmhSwitchDesktopHook W.greedyView
|
||||
. ewmh
|
||||
. dynamicEasySBs myStatusBars
|
||||
. docks
|
||||
. addAfterRescreenHook restartStatusBars
|
||||
. addRandrChangeHook (spawn myScreenHotplug)
|
||||
$ myConfig
|
||||
|
||||
@@ -182,13 +183,20 @@ myLayoutHook = onWorkspace wsWeb myWebLayout $ onWorkspace wsGames myGamesLayout
|
||||
delta = 3 / 100
|
||||
|
||||
-- Xmobar
|
||||
-- One bar per connected screen. The laptop config leaves room for trayer, so it
|
||||
-- goes on the laptop screen, which is screen 1 with HDMI and screen 0 without.
|
||||
myStatusBars :: ScreenId -> X StatusBarConfig
|
||||
myStatusBars (S i) = do
|
||||
nScreens <- gets (length . W.screens . windowset)
|
||||
let rc = if nScreens > 1 && i /= 1 then "xmobarrc_hdmi" else "xmobarrc_laptop"
|
||||
pure $ statusBarProp ("xmobar -x " ++ show i ++ " ~/.config/xmobar/" ++ rc) (clickablePP myXmobarPP)
|
||||
-- The laptop config leaves room for trayer, so it goes on the laptop screen,
|
||||
-- which is screen 1 with HDMI and screen 0 without.
|
||||
myStatusBar :: Int -> Int -> String
|
||||
myStatusBar nScreens i = "xmobar -x " ++ show i ++ " ~/.config/xmobar/" ++ rc
|
||||
where
|
||||
rc = if nScreens > 1 && i /= 1 then "xmobarrc_hdmi" else "xmobarrc_laptop"
|
||||
|
||||
-- One bar per screen, all restarted on every screen change: the right config for a
|
||||
-- screen id depends on the screen count, and dynamicSBs would keep the old bar
|
||||
restartStatusBars :: X ()
|
||||
restartStatusBars = do
|
||||
killAllStatusBars
|
||||
screens <- gets (W.screens . windowset)
|
||||
forM_ screens $ \s -> let S i = W.screen s in spawnStatusBar (myStatusBar (length screens) i)
|
||||
|
||||
myXmobarPP :: PP
|
||||
myXmobarPP =
|
||||
@@ -219,7 +227,9 @@ myXmobarPP =
|
||||
-- Autostart
|
||||
myStartupHook :: X ()
|
||||
myStartupHook = do
|
||||
restartStatusBars
|
||||
spawnOnce myScreenSetup
|
||||
spawnOnce "systemctl --user start fehbg.timer"
|
||||
spawnOnce "xsetroot -cursor_name left_ptr"
|
||||
spawnOnce "xautolock -time 10 -locker slock -detectsleep"
|
||||
spawnOnce "systemctl --user start xautolock-inhibit"
|
||||
@@ -228,7 +238,7 @@ myStartupHook = do
|
||||
spawnOnce "nm-applet"
|
||||
spawnOnce "arch-audit-gtk"
|
||||
spawnOnce "calcurse --daemon"
|
||||
spawnOnce "dunst"
|
||||
spawnOnce "systemctl --user start dunst"
|
||||
spawnOnce "lxpolkit"
|
||||
spawnOnce "numlockx"
|
||||
spawnOnce "blueman-applet"
|
||||
@@ -289,7 +299,9 @@ myHandleEventHook =
|
||||
|
||||
-- Log hook
|
||||
myLogHook :: X ()
|
||||
myLogHook = raiseDiscoverOverlay
|
||||
myLogHook = do
|
||||
raiseDiscoverOverlay
|
||||
xmonadPropLog =<< dynamicLogString =<< clickablePP myXmobarPP
|
||||
|
||||
-- discover-overlay's windows are override-redirect, so xmonad doesn't manage them and
|
||||
-- raising a floating window (e.g. a game) covers them; put them back on top after every change
|
||||
|
||||
Reference in new issue
Block a user