mirror of
https://github.com/elkowar/dots-of-war.git
synced 2024-11-06 03:12:24 +00:00
Add BACKGROUND-QUTEBROWSER-INSTANCES
This commit is contained in:
parent
6baba38cd7
commit
975c6265d7
1 changed files with 2 additions and 2 deletions
|
@ -250,7 +250,7 @@ myKeys =
|
|||
, ("M-f", toggleFullscreen)
|
||||
|
||||
, ("M-b", launchWithBackgroundInstance (className =? "qutebrowser") "bwrap --bind / / --dev-bind /dev /dev --tmpfs /tmp --tmpfs /run qutebrowser")
|
||||
, ("M-S-<Return>", launchWithBackgroundInstance (className =? "Alacritty") "alacritty")
|
||||
, ("M-S-<Return>", launchWithBackgroundInstance (className =? "Alacritty") "alacritty")
|
||||
|
||||
, ("M-S-C-c", kill1)
|
||||
, ("M-S-C-q", io exitSuccess)
|
||||
|
@ -331,7 +331,7 @@ myKeys =
|
|||
-- For this to work, the window needs to have the `_NET_WM_PID` set and unique!
|
||||
launchWithBackgroundInstance :: (Query Bool) -> String -> X ()
|
||||
launchWithBackgroundInstance windowQuery commandToRun = withWindowSet $ \winSet -> do
|
||||
quteWins <- (W.allWindows winSet) |> filter (\win -> Just True == fmap ("NSP" ==) (W.findTag win winSet))
|
||||
quteWins <- (W.allWindows winSet) |> filter (\win -> Just True == (("NSP" ==) <$> (W.findTag win winSet)))
|
||||
|> filterM (runQuery windowQuery)
|
||||
case quteWins of
|
||||
[] -> do spawnHere commandToRun
|
||||
|
|
Loading…
Reference in a new issue