cabal patch to improve "cabal update" behavior.

Eyal Lotem eyal.lotem at
Tue Apr 17 09:32:37 CEST 2012

I built a preliminary prototype of "cabal update" enhancements:

A) Using a Lazy I/O bytestring with the HTTP download, so that it can do a
streaming-decompress on-the-fly (This gives a 30% speedup on my machine)

B) Using the bytestring-progress library to show a useful progress report
on the whole process. Unfortunately, due to the PVP, the version
constraints are (as usual) over-restrictive, so they need to be relaxed.
Until the fix is put on hackage, you have to install bytestring-progress

C) It's quick&dirty (Proof of concept), because:
C.1) No version constraints on bytestring-progress
C.2) Using hSetBuffering on stdout and ANSI terminal codes, which may be
problematic in different kinds of terminals
C.3) The only way to disable it is setting verbosity=quiet. It probably
deserves its own option

I hope it's a useful demonstration of the utility of this, though. It makes
"cabal update" something I'd dread a little less to run :)

Also, I was wondering why there's no monad for the passing of Verbosity
around to so many functions. Then I could easily add more options that go
around to control things like whether to show progress bars...

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cabal.bundle
Type: application/octet-stream
Size: 61605 bytes
Desc: not available
URL: <>

More information about the cabal-devel mailing list