module Main where import qualified Data.Map.Strict as M import Program (handleAndParseFile) import Repl main :: IO () main = do args <- getArgs case args of [] -> void repl files -> handleFiles files handleFiles :: [String] -> IO () handleFiles [] = putTextLn "success!" handleFiles (file : rest) = runExceptT (handleAndParseFile M.empty file) >>= either putStrLn (const $ handleFiles rest)