{-# LANGUAGE DeriveDataTypeable #-}

module Config where

import System.Console.CmdArgs

data Config = Get { repos :: [String] }
            | Run { fast  :: Bool
                  , dump  :: Bool
                  , extra :: [String] }
              deriving (Show, Data, Typeable)

defaultConfig =
 [ mode $ Get { repos = []   &= args & typ "REPONAME" }
 , mode $ Run { fast = False &= text "Exclude the most time-consuming benchmarks"
              , dump = False &= text "Produce machine-readable output on stdout"
              , extra = []   &= args & typ "BINARY"
              }
 ]

