Compare commits
4
Commits
| 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.
|
# 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.
|
# 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)
|
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
|
# 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
|
. ewmhFullscreen
|
||||||
. setEwmhSwitchDesktopHook W.greedyView
|
. setEwmhSwitchDesktopHook W.greedyView
|
||||||
. ewmh
|
. ewmh
|
||||||
. dynamicEasySBs myStatusBars
|
. docks
|
||||||
|
. addAfterRescreenHook restartStatusBars
|
||||||
. addRandrChangeHook (spawn myScreenHotplug)
|
. addRandrChangeHook (spawn myScreenHotplug)
|
||||||
$ myConfig
|
$ myConfig
|
||||||
|
|
||||||
@@ -182,13 +183,20 @@ myLayoutHook = onWorkspace wsWeb myWebLayout $ onWorkspace wsGames myGamesLayout
|
|||||||
delta = 3 / 100
|
delta = 3 / 100
|
||||||
|
|
||||||
-- Xmobar
|
-- Xmobar
|
||||||
-- One bar per connected screen. The laptop config leaves room for trayer, so it
|
-- The laptop config leaves room for trayer, so it goes on the laptop screen,
|
||||||
-- goes on the laptop screen, which is screen 1 with HDMI and screen 0 without.
|
-- which is screen 1 with HDMI and screen 0 without.
|
||||||
myStatusBars :: ScreenId -> X StatusBarConfig
|
myStatusBar :: Int -> Int -> String
|
||||||
myStatusBars (S i) = do
|
myStatusBar nScreens i = "xmobar -x " ++ show i ++ " ~/.config/xmobar/" ++ rc
|
||||||
nScreens <- gets (length . W.screens . windowset)
|
where
|
||||||
let rc = if nScreens > 1 && i /= 1 then "xmobarrc_hdmi" else "xmobarrc_laptop"
|
rc = if nScreens > 1 && i /= 1 then "xmobarrc_hdmi" else "xmobarrc_laptop"
|
||||||
pure $ statusBarProp ("xmobar -x " ++ show i ++ " ~/.config/xmobar/" ++ rc) (clickablePP myXmobarPP)
|
|
||||||
|
-- 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 :: PP
|
||||||
myXmobarPP =
|
myXmobarPP =
|
||||||
@@ -219,7 +227,9 @@ myXmobarPP =
|
|||||||
-- Autostart
|
-- Autostart
|
||||||
myStartupHook :: X ()
|
myStartupHook :: X ()
|
||||||
myStartupHook = do
|
myStartupHook = do
|
||||||
|
restartStatusBars
|
||||||
spawnOnce myScreenSetup
|
spawnOnce myScreenSetup
|
||||||
|
spawnOnce "systemctl --user start fehbg.timer"
|
||||||
spawnOnce "xsetroot -cursor_name left_ptr"
|
spawnOnce "xsetroot -cursor_name left_ptr"
|
||||||
spawnOnce "xautolock -time 10 -locker slock -detectsleep"
|
spawnOnce "xautolock -time 10 -locker slock -detectsleep"
|
||||||
spawnOnce "systemctl --user start xautolock-inhibit"
|
spawnOnce "systemctl --user start xautolock-inhibit"
|
||||||
@@ -228,7 +238,7 @@ myStartupHook = do
|
|||||||
spawnOnce "nm-applet"
|
spawnOnce "nm-applet"
|
||||||
spawnOnce "arch-audit-gtk"
|
spawnOnce "arch-audit-gtk"
|
||||||
spawnOnce "calcurse --daemon"
|
spawnOnce "calcurse --daemon"
|
||||||
spawnOnce "dunst"
|
spawnOnce "systemctl --user start dunst"
|
||||||
spawnOnce "lxpolkit"
|
spawnOnce "lxpolkit"
|
||||||
spawnOnce "numlockx"
|
spawnOnce "numlockx"
|
||||||
spawnOnce "blueman-applet"
|
spawnOnce "blueman-applet"
|
||||||
@@ -289,7 +299,9 @@ myHandleEventHook =
|
|||||||
|
|
||||||
-- Log hook
|
-- Log hook
|
||||||
myLogHook :: X ()
|
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
|
-- 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
|
-- 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