2016-09-12 21:01:08 -06:00
|
|
|
import System.IO
|
|
|
|
|
2016-09-09 18:48:28 -06:00
|
|
|
import XMonad
|
|
|
|
import XMonad.Config()
|
2016-09-12 21:01:08 -06:00
|
|
|
import XMonad.Hooks.DynamicLog
|
2016-09-13 03:50:25 -06:00
|
|
|
import XMonad.Hooks.EwmhDesktops
|
2016-09-13 13:51:06 -06:00
|
|
|
import XMonad.Hooks.ManageDocks
|
|
|
|
import XMonad.Util.EZConfig
|
2016-09-12 21:01:08 -06:00
|
|
|
import XMonad.Util.Run(spawnPipe)
|
2016-09-13 03:50:25 -06:00
|
|
|
|
2016-09-13 13:51:06 -06:00
|
|
|
-- Use Super/Command/WinKey instead of Alt
|
|
|
|
myModMask :: KeyMask
|
|
|
|
myModMask = mod4Mask
|
2016-09-09 18:48:28 -06:00
|
|
|
|
|
|
|
main :: IO ()
|
2016-09-12 21:01:08 -06:00
|
|
|
main = do
|
|
|
|
xmproc <- spawnPipe "xmobar"
|
2016-09-13 13:51:06 -06:00
|
|
|
xmonad $ ewmh def
|
|
|
|
{ modMask = myModMask
|
|
|
|
, terminal = "urxvt"
|
|
|
|
, layoutHook = avoidStruts $ layoutHook def
|
|
|
|
, logHook = dynamicLogWithPP xmobarPP
|
|
|
|
{ ppOutput = hPutStrLn xmproc
|
|
|
|
, ppTitle = xmobarColor "green" "" . shorten 50
|
|
|
|
}
|
|
|
|
, handleEventHook = handleEventHook def <+> fullscreenEventHook
|
|
|
|
, startupHook = myStartup
|
|
|
|
} `additionalKeys`
|
|
|
|
[ ((myModMask, xK_p), spawn "rofi -show drun")
|
|
|
|
, ((myModMask, xK_g), spawn "rofi -show window")
|
|
|
|
-- TODO: Change this to bringing the window to the current workspace
|
|
|
|
, ((myModMask, xK_b), spawn "rofi -show run")
|
|
|
|
]
|
2016-09-09 18:48:28 -06:00
|
|
|
|
2016-09-13 13:51:06 -06:00
|
|
|
myStartup :: X()
|
|
|
|
myStartup = do
|
|
|
|
spawn "stalonetray"
|
2016-09-13 18:50:42 -06:00
|
|
|
spawn "nm-applet --sm-disable"
|
2016-09-13 13:51:06 -06:00
|
|
|
spawn "xsetroot -solid black"
|
|
|
|
-- TODO: Figure out how to set different backgrounds for different x
|
|
|
|
-- monitors
|
|
|
|
-- spawn "feh --bg-scale /usr/share/backgrounds/gnome/Blinds.jpg"
|
|
|
|
spawn "copyq"
|