diff options
| -rw-r--r-- | Plugins/HelloWorld.hs | 6 | ||||
| -rw-r--r-- | Runnable.hs | 6 | ||||
| -rw-r--r-- | Runnable.hs-boot | 4 | ||||
| -rw-r--r-- | XMobar.hs | 2 | 
4 files changed, 8 insertions, 10 deletions
| diff --git a/Plugins/HelloWorld.hs b/Plugins/HelloWorld.hs index 2b52506..8e68713 100644 --- a/Plugins/HelloWorld.hs +++ b/Plugins/HelloWorld.hs @@ -16,10 +16,10 @@ module Plugins.HelloWorld where  import Commands -data Plugin = HelloWorld -    deriving (Show, Read) +data HelloWorld = HelloWorld +    deriving (Read) -instance Exec Plugin where +instance Exec HelloWorld where      run HelloWorld = return "<fc=red>Hello World!!</fc>"      rate HelloWorld = 1000      alias HelloWorld = "helloWorld" diff --git a/Runnable.hs b/Runnable.hs index 9191697..2f55e7f 100644 --- a/Runnable.hs +++ b/Runnable.hs @@ -26,10 +26,8 @@ import Text.ParserCombinators.ReadPrec  import Config (runnableTypes)  import Commands -data Runnable = forall r . (Exec r,Show r, Read r) => Run r +data Runnable = forall r . (Exec r, Read r) => Run r -instance Show Runnable where -    show (Run a) = "Run " ++ show a  instance Exec Runnable where       run (Run a) = run a @@ -46,7 +44,7 @@ class ReadAsAnyOf ts ex where  instance ReadAsAnyOf () ex where       readAsAnyOf ~() = mzero -instance (Read t, Show t, Exec t, ReadAsAnyOf ts Runnable) => ReadAsAnyOf (t,ts) Runnable where  +instance (Read t, Exec t, ReadAsAnyOf ts Runnable) => ReadAsAnyOf (t,ts) Runnable where       readAsAnyOf ~(t,ts) = r t `mplus` readAsAnyOf ts                where r ty = do { m <- readPrec; return (Run (m `asTypeOf` ty)) } diff --git a/Runnable.hs-boot b/Runnable.hs-boot index 90dbe81..bef4e39 100644 --- a/Runnable.hs-boot +++ b/Runnable.hs-boot @@ -2,10 +2,10 @@  module Runnable where  import Commands -data Runnable = forall r . (Exec r,Show r, Read r) => Run r +data Runnable = forall r . (Exec r,Read r) => Run r  instance Read Runnable  instance Exec Runnable -instance Show Runnable + @@ -181,7 +181,7 @@ execCommand c com =  runCommandLoop :: MVar String -> Config -> (Runnable,String,String) -> IO ()  runCommandLoop var conf c@(com,s,ss) -    | show com == "" =  +    | alias com == "" =           do modifyMVar_ var (\_ -> return $ "Could not parse the template")             tenthSeconds (refresh conf)             runCommandLoop var conf c | 
