1. Stefan Saasen
  2. git-in-haskell-from-the-bottom-up

Commits

Stefan Saasen  committed 0d9ecff

Main: Show usage on error

  • Participants
  • Parent commits 711556d
  • Branches master

Comments (0)

Files changed (1)

File src/Main.hs

View file
  • Ignore whitespace
     args <- getArgs
     case args of
         (cmd:xs)    -> run cmd xs
-        _           -> error "Missing command"
+        _           -> error "usage: hgit clone <repo> [<dir>]"
 
 -- | Execute the given command
 run :: String -> [String] -> IO ()