mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-09-01 11:53:48 -07:00
Use getXMonadDir to get the default xmonad directory.
This commit is contained in:
@@ -26,8 +26,6 @@ module XMonad.Hooks.Script (
|
|||||||
--
|
--
|
||||||
import XMonad
|
import XMonad
|
||||||
|
|
||||||
import System.Directory
|
|
||||||
|
|
||||||
-- $usage
|
-- $usage
|
||||||
--
|
--
|
||||||
-- This module allows you to run a centrally located script with the text
|
-- This module allows you to run a centrally located script with the text
|
||||||
@@ -47,7 +45,7 @@ import System.Directory
|
|||||||
|
|
||||||
-- | Execute a named script hook
|
-- | Execute a named script hook
|
||||||
execScriptHook :: MonadIO m => String -> m ()
|
execScriptHook :: MonadIO m => String -> m ()
|
||||||
execScriptHook hook = io $ do
|
execScriptHook hook = do
|
||||||
home <- getHomeDirectory
|
xmonadDir <- getXMonadDir
|
||||||
let script = home ++ "/.xmonad/hooks "
|
let script = xmonadDir ++ "/hooks "
|
||||||
spawn (script ++ hook)
|
spawn (script ++ hook)
|
||||||
|
Reference in New Issue
Block a user