Pester the user with one (not two) xmessages on config errors

This commit is contained in:
Adam Vogt 2009-03-21 23:37:36 +00:00
parent d9d3e40112
commit 66e7715ea6
2 changed files with 4 additions and 2 deletions

View File

@ -16,10 +16,12 @@ module Main (main) where
import XMonad
import Control.Monad (unless)
import System.IO
import System.Info
import System.Environment
import System.Posix.Process (executeFile)
import System.Exit (exitFailure)
import Paths_xmonad (version)
import Data.Version (showVersion)
@ -39,7 +41,7 @@ main = do
[] -> launch
["--resume", _] -> launch
["--help"] -> usage
["--recompile"] -> recompile True >> return ()
["--recompile"] -> recompile True >>= flip unless exitFailure
["--restart"] -> sendRestart >> return ()
["--version"] -> putStrLn ("xmonad " ++ showVersion version)
#ifdef TESTING

View File

@ -218,7 +218,7 @@ keys conf@(XConfig {XMonad.modMask = modMask}) = M.fromList $
-- quit, or restart
, ((modMask .|. shiftMask, xK_q ), io (exitWith ExitSuccess)) -- %! Quit xmonad
, ((modMask , xK_q ), spawn "xmonad --recompile; xmonad --restart") -- %! Restart xmonad
, ((modMask , xK_q ), spawn "xmonad --recompile && xmonad --restart") -- %! Restart xmonad
]
++
-- mod-[1..9] %! Switch to workspace N