16

Is it possible to (ab)use Cabal to have it create a generic Haskell project with a simple command, similar to what you can do in the Scala world with Sbt or Maven?

e.g.

> cabal create AwesomeProject
> ls
AwesomeProject.hs     awesomeProject.cabal     LICENSE     README     Setup.hs 

or is there another tool for that?

1 Answer 1

27

Use cabal init --interactive to have an interactive session with cabal. I've pasted the first few questions when using the command:

arash@arash-ThinkPad-SL510:~/test$ cabal init
Package name [default "test"]? 
Package version [default "0.1"]? 
Please choose a license:
   1) GPL
   2) GPL-2
   3) GPL-3
   4) LGPL
   5) LGPL-2.1
   6) LGPL-3
 * 7) BSD3
   8) BSD4
   9) MIT
  10) PublicDomain
  11) AllRightsReserved
  12) OtherLicense
  13) Other (specify)
Your choice [default "BSD3"]? 
Author name? MyName 
Maintainer email? 

Hope this helps.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.