[xmonad] Looking for "runOrKill" function

Sepp Tannhuber sepp.tannhuber at yahoo.de
Wed Sep 24 20:40:51 UTC 2014


I found
http://splash-of-open-sauce.blogspot.de/2011/02/xmonadhs-haskell-xmonad-config-file.html
which looks similar to my config:

--- BEGIN ---
scratchpads = [ 
     NS "calendar" "urxvt -name calendar -e task calendar" (title =? "calendar")
 ] where name = stringProperty "WM_NAME"


main = do
  dzenLeftBar  <- spawnPipe myXmonadBar
  dzenRightBar <- spawnPipe myStatusBar
  dzenTrayerBar <- spawnPipe myTrayerBar
  xmonad $ ewmh $ withUrgencyHook NoUrgencyHook defaultConfig
    { focusFollowsMouse  = True
    , modMask            = mod3Mask
    , workspaces         = myWorkspaces
    , manageHook         = namedScratchpadManageHook scratchpads <+> manageDocks <+> myManageHook
{- ... -}
    , ((mod3Mask, xK_d),               namedScratchpadAction scratchpads "calendar")
--- END ---

The result is:
--- BEGIN ---
Error detected while loading xmonad configuration file: /home/sepp/.xmonad/xmonad.hs

xmonad.hs:195:54:
    Couldn't match type `ManageHook -> NamedScratchpad'
                  with `NamedScratchpad'
    Expected type: NamedScratchpads
      Actual type: [ManageHook -> NamedScratchpad]
    In the first argument of `namedScratchpadManageHook', namely
      `scratchpads'
    In the first argument of `(<+>)', namely
      `namedScratchpadManageHook scratchpads'
    In the first argument of `(<+>)', namely
      `namedScratchpadManageHook scratchpads <+> manageDocks'

xmonad.hs:216:62:
    Couldn't match type `ManageHook -> NamedScratchpad'
                  with `NamedScratchpad'
    Expected type: NamedScratchpads
      Actual type: [ManageHook -> NamedScratchpad]
    In the first argument of `namedScratchpadAction', namely
      `scratchpads'
    In the expression: namedScratchpadAction scratchpads "calendar"
    In the expression:
      ((mod3Mask, xK_d), namedScratchpadAction scratchpads "calendar")

Please check the file for errors.
--- END ---


More information about the xmonad mailing list