
Hi all, I'd like a tool that takes a .cabal file as input and produces a list of all dependencies (recursive, all the way to 'base') and some metadata for each (most importantly, LICENSE) Does this already exist, or will I to write it myself? I notice that there's a patch by Trevor Elliot to either Cabal or cabal-install that does something similar [1], and I know that Magnus Therning wrote a little tool that creates a GraphViz graph [2]... so it seems like all the pieces are there already. But is there anything in some sort of ready-to-go just-works state, doing everything including interacting with hackage and sucking down the cabal files it needs, etc? Thanks, Eric [1]: http://www.haskell.org/pipermail/cabal-devel/2010-October/006657.html [2]: http://therning.org/magnus/archives/534 -- Eric Kow http://erickow.com

On Mon, Oct 10, 2011 at 11:53 AM, Eric Y. Kow
I notice that there's a patch by Trevor Elliot to either Cabal or cabal-install that does something similar [1], and I know that Magnus Therning wrote a little tool that creates a GraphViz graph [2]... so it seems like all the pieces are there already. But is there anything in some sort of ready-to-go just-works state, doing everything including interacting with hackage and sucking down the cabal files it needs, etc?
Talking about Hackage, in an ideal Hackage this information should be displayed right into the package's front page as well. One may have wishes, right? =) Cheers, -- Felipe.

On Mon, 10 Oct 2011 16:53:29 +0200, Eric Y. Kow
Hi all,
I'd like a tool that takes a .cabal file as input and produces a list of all dependencies (recursive, all the way to 'base') and some metadata for each (most importantly, LICENSE)
Does this already exist, or will I to write it myself?
I notice that there's a patch by Trevor Elliot to either Cabal or cabal-install that does something similar [1], and I know that Magnus Therning wrote a little tool that creates a GraphViz graph [2]... so it seems like all the pieces are there already. But is there anything in some sort of ready-to-go just-works state, doing everything including interacting with hackage and sucking down the cabal files it needs, etc?
cab[0] can do that, for installed packages:
cab deps -i -r -a vector
will generate a list of licenses for vector and the packages it depends
upon, like this:
base 4.3.1.0 BSD3 ""
ghc-prim 0.2.0.0 BSD3 ""
rts 1.0 BSD3 ""
ffi 1.0 BSD3 ""
integer-gmp 0.2.0.3 BSD3 ""
ghc-prim 0.2.0.0 BSD3 ""
rts 1.0 BSD3 ""
ffi 1.0 BSD3 ""
rts 1.0 BSD3 ""
ffi 1.0 BSD3 ""
primitive 0.4.0.1 BSD3 "Roman Leshchinskiy

On Mon, Oct 10, 2011 at 17:24:18 +0200, Henk-Jan van Tuyl wrote:
I'd like a tool that takes a .cabal file as input and produces a list of all dependencies (recursive, all the way to 'base') and some metadata for each (most importantly, LICENSE)
cab[0] can do that, for installed packages: cab deps -i -r -a vector
Thanks! That's close enough. -- Eric Kow http://erickow.com
participants (3)
-
Eric Y. Kow
-
Felipe Almeida Lessa
-
Henk-Jan van Tuyl