Some changes

This commit is contained in:
EEva 2021-08-25 04:51:46 +03:00
parent 33ae468829
commit 96fcfeee3f
3 changed files with 29 additions and 20 deletions

View file

@ -23,29 +23,36 @@ singleTermAppWithName name app = Project
-- safeSpawn "nvidia-offload" ["alacritty","-e","tmux","new","-A","-s",name]
-- }
singleAppWithName :: String -> String -> Project
singleAppWithName name app = Project
singleAppWithName' :: String -> String -> [String] -> Project
singleAppWithName' name app args = Project
{ projectName = name
, projectDirectory = "/tmp"
, projectStartHook = Just $ do spawn app
, projectStartHook = Just $ do safeSpawn app args
}
singleAppWithName :: String -> String -> Project
singleAppWithName name app = singleAppWithName' name app []
singleApp :: String -> Project
singleApp app = singleAppWithName app app
singleJackApp :: String -> Project
singleJackApp app = singleAppWithName' app "pw-jack" [app]
projects :: [Project]
projects =
[ singleApp "carla"
[ singleApp "m8c"
, singleApp "obs"
, singleApp "reaper"
, singleApp "m8c"
, singleApp "renoise"
, singleApp "steam"
, singleJackApp "carla"
, singleJackApp "reaper"
, singleJackApp "renoise"
, singleAppWithName "Books" "calibre"
, singleAppWithName "discord" "Discord"
, singleAppWithName "element" "element-desktop"
, singleAppWithName "signal" "signal-desktop"
, singleAppWithName "vcv" "Rack"
, singleAppWithName "youtube" "chromium"
, singleAppWithName' "vcv" "pw-jack" ["Rack"]
, singleTermAppWithName "email" "neomutt"
, Project { projectName = "admin"
, projectDirectory = "~/admin/nixos-config"

View file

@ -12,7 +12,7 @@ import qualified XMonad.StackSet as W
modify :: XConfig l -> XConfig l
modify conf = conf
{ manageHook = namedScratchpadManageHook pads
{ manageHook = manageHook conf <> namedScratchpadManageHook pads
}
pads =

View file

@ -29,24 +29,26 @@ import Scratchpad (modify)
layouts = toggleLayouts fullscreen tiled
where
smallBorder = SS.Border 5 5 5 5
fullscreen = (noBorders Full)
tiled = smarts $ resizableTall ||| (Mirror resizableTall)
smarts = (spacingRaw True smallBorder True smallBorder True) . smartBorders
fullscreen = noBorders Full
tiled = smarts $ resizableTall ||| Mirror resizableTall
smarts = spacingRaw True smallBorder True smallBorder True . smartBorders
resizableTall = ResizableTall 1 (5/100) (1/2) []
-- Use the `xprop' tool to get the info you need for these matches.
-- For className, use the second value that xprop gives you.
-------------- Here be the law of windows
myManageHook = composeOne
[ className =? "Pavucontrol" -?> doShift "music"
, className =? "Steam" -?> doShift "steam"
, className =? "Renoise" -?> hasBorder False
, className =? "REAPER" -?> hasBorder False
, className =? "Pinentry" -?> doCenterFloat
, isDialog -?> doCenterFloat
myManageHook = composeAll
[ className =? "Patchage" --> doShift "sound"
, className =? "Pavucontrol" --> doShift "music"
, className =? "Pinentry" --> doCenterFloat
, className =? "REAPER" --> hasBorder False
, className =? "Renoise" --> hasBorder False
, className =? "Steam" --> doShift "steam"
, className =? "csgo_linux64" --> doShift "steam"
, isDialog --> doCenterFloat
-- Move transient windows to their parent:
, transience
, transience'
]
------------ build the full config