Compare commits

..

2 Commits

Author SHA1 Message Date
Hektor Misplon 8d69407d71 Update xmonad statusbar(s) 2024-12-23 00:02:20 +01:00
Hektor Misplon 2590f238df Update XMonad imports 2024-12-22 23:58:23 +01:00
1 changed files with 15 additions and 15 deletions

View File

@ -1,9 +1,11 @@
-- {{{ Imports
import Control.Monad (liftM2)
import Data.Map qualified as M
import XMonad
import XMonad.Actions.CopyWindow (copyToAll, killAllOtherCopies)
import XMonad.Actions.FloatSnap
import XMonad.Actions.Submap
import XMonad.Hooks.EwmhDesktops
import XMonad.Hooks.ManageDocks
import XMonad.Hooks.ManageHelpers
@ -13,24 +15,23 @@ import XMonad.Hooks.StatusBar.PP
import XMonad.Hooks.WindowSwallowing (swallowEventHook)
import XMonad.Layout.CenteredIfSingle
import XMonad.Layout.IndependentScreens
import XMonad.Layout.LayoutHints (hintsEventHook, layoutHints)
import XMonad.Layout.PerScreen
import XMonad.Layout.PerWorkspace
import XMonad.Layout.Renamed
import XMonad.Layout.Spacing
import XMonad.Layout.Tabbed
import XMonad.Layout.ThreeColumns
import XMonad.StackSet qualified as W
import XMonad.Util.EZConfig
import XMonad.Util.Hacks qualified as Hacks
import XMonad.Util.Loggers
import XMonad.Util.Paste
import qualified XMonad.StackSet as W
import qualified XMonad.Util.Hacks as Hacks
-- }}}
-- Statusbar {{{
pp' :: ScreenId -> PP -> PP
pp' s pp = (marshallPP s pp) { ppSort = ppSort pp }
pp :: PP
pp =
def
@ -42,7 +43,7 @@ pp =
ppLayout = id,
ppTitle = shorten 80,
ppTitleSanitize = xmobarStrip,
ppOrder = \[workspaces, layout, windows, _] -> [workspaces, layout, windows],
ppOrder = \[workspaces, layout, windows, _] -> [layout],
ppExtras = [logTitles formatFocused formatUnfocused]
}
where
@ -72,7 +73,8 @@ shiftAndView = doF . liftM2 (.) W.greedyView W.shift
-- startupHook {{{
myStartupHook =
do
spawn "killall polybar && polybar -r"
spawn "killall -q polybar; parallel ::: 'polybar -r top' 'polybar -r bottom'"
-- }}}
-- manageHook {{{
@ -297,13 +299,11 @@ resetTemp = spawn "screen-temperature 3000"
main :: IO ()
main =
do { xmonad } $
ewmh $
withEasySB
(sb1 <> sb2)
do xmonad
$ ewmh
$ withEasySB
(statusBarProp "polybar" $ pure pp)
defToggleStrutsKey
myConfig
where
[sb1, sb2] = [statusBarProp "polybar" $ pure (pp' (S i) pp) | i <- [0 .. 1]]
-- }}}