mirror of
https://github.com/elkowar/dots-of-war.git
synced 2024-11-06 03:12:24 +00:00
asdf
This commit is contained in:
parent
400e99b517
commit
e6c782f53c
3 changed files with 28 additions and 22 deletions
Binary file not shown.
|
@ -1,6 +1,8 @@
|
||||||
{-# Language ScopedTypeVariables #-}
|
{-# Language ScopedTypeVariables #-}
|
||||||
module Config (main) where
|
|
||||||
-- Imports -------------------------------------------------------- {{{
|
-- Imports -------------------------------------------------------- {{{
|
||||||
|
module Config (main) where
|
||||||
|
|
||||||
|
|
||||||
import qualified Data.Map as M
|
import qualified Data.Map as M
|
||||||
import Data.List (isSuffixOf)
|
import Data.List (isSuffixOf)
|
||||||
import qualified Data.Maybe as Maybe
|
import qualified Data.Maybe as Maybe
|
||||||
|
@ -22,6 +24,7 @@ import XMonad.Hooks.DynamicLog
|
||||||
import XMonad.Hooks.ManageHelpers
|
import XMonad.Hooks.ManageHelpers
|
||||||
import XMonad.Hooks.FadeInactive
|
import XMonad.Hooks.FadeInactive
|
||||||
import XMonad.Hooks.ManageDocks
|
import XMonad.Hooks.ManageDocks
|
||||||
|
import XMonad.Hooks.EwmhDesktops (fullscreenEventHook)
|
||||||
import XMonad.Hooks.SetWMName (setWMName)
|
import XMonad.Hooks.SetWMName (setWMName)
|
||||||
import XMonad.Layout.Gaps
|
import XMonad.Layout.Gaps
|
||||||
import XMonad.Layout.LayoutHints
|
import XMonad.Layout.LayoutHints
|
||||||
|
@ -43,8 +46,8 @@ import XMonad.Util.SpawnOnce (spawnOnce)
|
||||||
|
|
||||||
myModMask = mod4Mask
|
myModMask = mod4Mask
|
||||||
myLauncher = "rofi -show run"
|
myLauncher = "rofi -show run"
|
||||||
--myTerminal = "termite"
|
myTerminal = "termite"
|
||||||
myTerminal = "kitty --single-instance"
|
--myTerminal = "kitty --single-instance"
|
||||||
myBrowser = "google-chrome-stable"
|
myBrowser = "google-chrome-stable"
|
||||||
--yBar = "xmobar"
|
--yBar = "xmobar"
|
||||||
--myXmobarPP= xmobarPP { ppCurrent = xmobarColor "#429942" "" . wrap "<" ">" }
|
--myXmobarPP= xmobarPP { ppCurrent = xmobarColor "#429942" "" . wrap "<" ">" }
|
||||||
|
@ -84,7 +87,7 @@ aqua = "#8ec07c"
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
-- Layout ---------------------------------------- {{{
|
-- Layout ---------------------------------------- {{{
|
||||||
myLayout = smartBorders $ withGaps $ toggleLayouts Full $ withSpacing $ layoutHints
|
myLayout = smartBorders $ toggleLayouts Full $ withSpacing $ layoutHints
|
||||||
( ResizableTall 1 (3/100) (1/2) []
|
( ResizableTall 1 (3/100) (1/2) []
|
||||||
||| Mirror (ResizableTall 1 (3/100) (3/4) [])
|
||| Mirror (ResizableTall 1 (3/100) (3/4) [])
|
||||||
||| spiral (6/7) -- Grid
|
||| spiral (6/7) -- Grid
|
||||||
|
@ -93,8 +96,8 @@ myLayout = smartBorders $ withGaps $ toggleLayouts Full $ withSpacing $ layoutH
|
||||||
-- mouseResizableTile ||| Mirror mouseResizableTile
|
-- mouseResizableTile ||| Mirror mouseResizableTile
|
||||||
where
|
where
|
||||||
-- add spacing between windows
|
-- add spacing between windows
|
||||||
withSpacing = spacingRaw True (Border 0 0 0 0) True (Border 10 10 10 10) True
|
withSpacing = spacingRaw True (Border 10 10 10 10) True (Border 10 10 10 10) True
|
||||||
withGaps = gaps' [((L, 10), True),((U, 10), True), ((D, 10), True), ((R, 10), True )]
|
--withGaps = gaps' [((L, 10), True),((U, 10), True), ((D, 10), True), ((R, 10), True )]
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
-- Loghook -------------------------------------- {{{
|
-- Loghook -------------------------------------- {{{
|
||||||
|
@ -102,11 +105,12 @@ myLayout = smartBorders $ withGaps $ toggleLayouts Full $ withSpacing $ layoutH
|
||||||
myLogHook :: X ()
|
myLogHook :: X ()
|
||||||
myLogHook = do
|
myLogHook = do
|
||||||
fadeInactiveLogHook 0.95 -- opacity of unfocused windows
|
fadeInactiveLogHook 0.95 -- opacity of unfocused windows
|
||||||
--(W.StackSet _ layout _ _ ) <- gets windowset
|
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
-- Startuphook ----------------------------- {{{
|
-- Startuphook ----------------------------- {{{
|
||||||
|
|
||||||
|
myStartupHook :: X ()
|
||||||
myStartupHook = do
|
myStartupHook = do
|
||||||
spawnOnce "picom --config ~/.config/picom.conf --no-fading-openclose"
|
spawnOnce "picom --config ~/.config/picom.conf --no-fading-openclose"
|
||||||
spawnOnce "pasystray"
|
spawnOnce "pasystray"
|
||||||
|
@ -117,8 +121,7 @@ myStartupHook = do
|
||||||
|
|
||||||
-- Keymap --------------------------------------- {{{
|
-- Keymap --------------------------------------- {{{
|
||||||
|
|
||||||
-- Default mappings that need to be removed
|
-- Default mappings that need to be removed removedKeys :: [String]
|
||||||
removedKeys :: [String]
|
|
||||||
removedKeys = ["M-S-c", "M-S-q"]
|
removedKeys = ["M-S-c", "M-S-q"]
|
||||||
|
|
||||||
myKeys :: [(String, X ())]
|
myKeys :: [(String, X ())]
|
||||||
|
@ -136,7 +139,7 @@ myKeys = [ ("M-C-k", sendMessage MirrorExpand)
|
||||||
, ("M-S-e", spawn "rofi -show emoji -modi emoji")
|
, ("M-S-e", spawn "rofi -show emoji -modi emoji")
|
||||||
, ("M-b", spawn myBrowser)
|
, ("M-b", spawn myBrowser)
|
||||||
, ("M-s", spawn $ scriptFile "rofi-search.sh")
|
, ("M-s", spawn $ scriptFile "rofi-search.sh")
|
||||||
, ("M-n", (spawn "echo 'n: terminal, h: ghci, w: WhatsApp' | dzen2 -p 1") >> scratchpadSubmap)
|
, ("M-n", spawn "echo 'n: terminal, h: ghci, w: WhatsApp' | dzen2 -p 1" >> scratchpadSubmap)
|
||||||
, ("M-e", promptExecute specialCommands)
|
, ("M-e", promptExecute specialCommands)
|
||||||
|
|
||||||
] ++ copyToWorkspaceMappings
|
] ++ copyToWorkspaceMappings
|
||||||
|
@ -176,12 +179,16 @@ myKeys = [ ("M-C-k", sendMessage MirrorExpand)
|
||||||
|
|
||||||
myManageHook :: Query (Data.Monoid.Endo WindowSet)
|
myManageHook :: Query (Data.Monoid.Endo WindowSet)
|
||||||
myManageHook = composeAll
|
myManageHook = composeAll
|
||||||
[ resource =? "Dialog" --> doFloat ]
|
[ resource =? "Dialog" --> doFloat
|
||||||
|
, isFullscreen --> doF W.focusDown <+> doFullFloat
|
||||||
|
, manageDocks
|
||||||
|
, namedScratchpadManageHook scratchpads
|
||||||
|
]
|
||||||
|
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
-- Main ------------------------------------ {{{
|
-- Main ------------------------------------ {{{
|
||||||
|
main :: IO ()
|
||||||
main = do
|
main = do
|
||||||
dbus <- D.connectSession
|
dbus <- D.connectSession
|
||||||
-- Request access to the DBus name
|
-- Request access to the DBus name
|
||||||
|
@ -190,19 +197,18 @@ main = do
|
||||||
|
|
||||||
-- $ ewmh (kills IntelliJ)
|
-- $ ewmh (kills IntelliJ)
|
||||||
xmonad $ desktopConfig
|
xmonad $ desktopConfig
|
||||||
{ terminal = myTerminal
|
{ terminal = myTerminal
|
||||||
, modMask = myModMask
|
, modMask = myModMask
|
||||||
, borderWidth = 1
|
, borderWidth = 1
|
||||||
, layoutHook = avoidStruts $ myLayout
|
, layoutHook = avoidStruts myLayout
|
||||||
, logHook = myLogHook <+> logHook desktopConfig <+> dynamicLogWithPP (polybarPP dbus)
|
, logHook = myLogHook <+> dynamicLogWithPP (polybarPP dbus) <+> logHook def
|
||||||
, startupHook = myStartupHook <+> startupHook desktopConfig
|
, startupHook = myStartupHook <+> startupHook def
|
||||||
, manageHook = manageDocks <+> myManageHook <+> (namedScratchpadManageHook scratchpads) <+> manageHook def <+> (isFullscreen --> doF W.focusDown <+> doFullFloat)
|
, manageHook = myManageHook <+> manageHook def
|
||||||
|
--, handleEventHook = fullscreenEventHook
|
||||||
, focusedBorderColor = aqua
|
, focusedBorderColor = aqua
|
||||||
, normalBorderColor = "#282828"
|
, normalBorderColor = "#282828"
|
||||||
} `removeKeysP` removedKeys `additionalKeysP` myKeys
|
} `removeKeysP` removedKeys `additionalKeysP` myKeys
|
||||||
|
|
||||||
-- xmonad =<< statusBar myBar myPP toggleStrutsKey myConfig
|
|
||||||
|
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
-- POLYBAR Kram -------------------------------------- {{{
|
-- POLYBAR Kram -------------------------------------- {{{
|
||||||
|
|
Binary file not shown.
Loading…
Reference in a new issue