[Haskell-cafe] Building examples with Cabal

Ozgur Akgun ozgurakgun at gmail.com
Fri Oct 18 09:28:17 UTC 2013


On 18 October 2013 08:07, Sven Panne <svenpanne at gmail.com> wrote:

> The only missing part is some way to build tons of
> executables in parallel without writing a .cabal file of roughly the
> same size as "The Lord of the Rings" or a typical Stephen King
> novel...

If you have so many tests, why wouldn't you generate a single executable
which takes the name of the test as an argument and runs that test?

Something like the following, with additional error checking and etc.

data Test = Foo | Bar | ...
runTest :: Test -> IO ()
main = do
  (t:_) <- getArgs
  runTest (read t)

This is a pretty simple idea, just wanted to know why you don't go down
this path instead.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20131018/9e293def/attachment.html>

More information about the Haskell-Cafe mailing list