diff --git a/nix/configurations/vanadium/home/xmonad/xmonad.hs b/nix/configurations/vanadium/home/xmonad/xmonad.hs index 50724ef3..b6ee4e7b 100644 --- a/nix/configurations/vanadium/home/xmonad/xmonad.hs +++ b/nix/configurations/vanadium/home/xmonad/xmonad.hs @@ -86,14 +86,7 @@ isEvolution :: Query Bool isEvolution = className ~? "gnome.Evolution" isEvolutionComposer :: Query Bool -isEvolutionComposer = - isEvolution <&&> - (fmap or . sequence) - [ title =? "Compose Message" - , title ^? "Re: " -- reply message composer - , title ^? "Appointment" -- calendar event editor - , title ^? "Meeting" -- calendar event editor - ] +isEvolutionComposer = isEvolution <&&> title =? "Compose Message" isFirefox :: Query Bool isFirefox = className =? "firefox" @@ -191,16 +184,13 @@ doShiftAndGreedyView n = doF . go =<< ask where go :: Window -> WindowSet -> WindowSet go w s = W.greedyView n $ W.shiftWin n w s -queryWindowSet :: Query WindowSet -queryWindowSet = liftX $ gets windowset +hasProp :: (Window -> WindowSet -> Bool) -> Query Bool +hasProp f = f <$> ask <*> (liftX $ gets windowset) windowIsInCurrentWorkspace :: Query Bool -windowIsInCurrentWorkspace = do - w <- ask - s <- queryWindowSet - pure $ case W.findTag w s of - Just from | from == W.currentTag s -> True - _ -> False +windowIsInCurrentWorkspace = hasProp $ \w s -> case W.findTag w s of + Just from | from == W.currentTag s -> True + _ -> False myStartupHook :: X () myStartupHook = do diff --git a/nix/packages/by-name/ruler/package.nix b/nix/packages/by-name/ruler/package.nix index 535d9cba..1a7da098 100644 --- a/nix/packages/by-name/ruler/package.nix +++ b/nix/packages/by-name/ruler/package.nix @@ -11,8 +11,8 @@ let domain = "git.confusedcompiler.org"; owner = "leana8959"; repo = "ruler"; - rev = "0cad6d87e2e607b39fe72fc292924c069e661293"; - hash = "sha256-AIjGG2FxMiojO1E8jJxBXs9ZaRy3OEAtEp5CwicllRE="; + rev = "00b6c4f1b5d764b049028ba4207ca1dc8ad74f2b"; + hash = "sha256-CI9jKcNoFqv4AgQIFFkqafcg2ybs2MN+RaEnuv72Mbc="; }) { }; cabalOverrides = o: {