Re: Providing a smooth default user experience

2012-11-02 Thread Björn Peemöller
Am 31.10.2012 18:22, schrieb Johan Tibell: > *We should add a cabal run command* [snip] > I think we could improve this use case by introducing a new command, > cabal run, with the following parameters: > > cabal run > > which would run > > cabal build > dist/build// I like this idea, but

Re: Providing a smooth default user experience

2012-11-02 Thread Simon Hengel
> Recently, I had to add a MIN_VERSION macro to my code because of the > old-time / time change in directory, but couldn't test the library in > ghci because the macro was not defined. > > I discovered that configuring ghci with > > :set -optP-include -optPdist/build/autogen/cabal_macros.h > >

Re: Providing a smooth default user experience

2012-11-02 Thread Simon Hengel
On Fri, Nov 02, 2012 at 11:25:11AM +0100, Simon Hengel wrote: > > Recently, I had to add a MIN_VERSION macro to my code because of the > > old-time / time change in directory, but couldn't test the library in > > ghci because the macro was not defined. > > > > I discovered that configuring ghci wi

Re: Providing a smooth default user experience

2012-11-02 Thread Mikhail Glushenkov
Hi, On Fri, Nov 2, 2012 at 10:48 AM, Björn Peemöller wrote: > > So, if I'm not missing something, it may also be comfortable to add a > > cabal ghci > > command which tells ghci about cabal's configuration. There was a "cabal repl" GSoC project last year. The patches haven't been merged yet, sin

Re: Providing a smooth default user experience

2012-11-02 Thread Duncan Coutts
On Fri, 2012-11-02 at 11:25 +0100, Simon Hengel wrote: > > Recently, I had to add a MIN_VERSION macro to my code because of the > > old-time / time change in directory, but couldn't test the library in > > ghci because the macro was not defined. > > > > I discovered that configuring ghci with > >

Re: Providing a smooth default user experience

2012-11-02 Thread Duncan Coutts
On Wed, 2012-10-31 at 10:22 -0700, Johan Tibell wrote: > Hi all, > > Sensible defaults are important to provide a smooth user experience, > especially for first-time users. There are a few areas where I think cabal > could improve its default behavior. In particular, here are a couple of > changes

Re: Providing a smooth default user experience

2012-11-02 Thread Simon Hengel
Duncan, > > Moreover, it would be awesome if it would regenerate generated source > > files on :reload. I'm not sure if this is feasible without changes to > > GHCi, but a custom macro, e.g. > > > > :cabal-reload > > > > could still work. > > The GSoC project that started this off did that