Send Beginners mailing list submissions to beginners@haskell.org To subscribe or unsubscribe via the World Wide Web, visit http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners or, via email, send a message with subject or body 'help' to beginners-requ...@haskell.org
You can reach the person managing the list at beginners-ow...@haskell.org When replying, please edit your Subject line so it is more specific than "Re: Contents of Beginners digest..." Today's Topics: 1. Trying to install "Craft3e" from Hackage using stack (Albin Otterh?ll) 2. Re: Trying to install "Craft3e" from Hackage using stack (Simon Jakobi) 3. Re: Trying to install "Craft3e" from Hackage using stack (Albin Otterh?ll) ---------------------------------------------------------------------- Message: 1 Date: Sat, 16 Apr 2016 01:06:04 +0200 From: Albin Otterh?ll <gm...@otterhall.com> To: beginners@haskell.org Subject: [Haskell-beginners] Trying to install "Craft3e" from Hackage using stack Message-ID: <ners58$msg$1...@ger.gmane.org> Content-Type: text/plain; charset=utf-8 I'm currently reading "Haskell: the Craft of Functional Programming", by Simon Thompson and I'm trying to download and install the package books code. But when I run "stack build Craft3e" I get the following error message: > Run from outside a project, using implicit global project config > Using resolver: lts-5.12 from implicit global project's config file: > /home/dumbl3d0re/.stack/global-project/stack.yaml > While constructing the BuildPlan the following exceptions were encountered: > > -- Failure when adding dependencies: > HUnit: needed (==1.2.*), 1.3.1.1 found (latest applicable is 1.2.5.2) > mtl: needed (>=1.1 && <2.2), 2.2.1 found (latest applicable is 2.1.3.1) > needed for package Craft3e-0.1.0.10 How should I go about to install "Craft3e"? Thanks in advance! Regards, Albin ------------------------------ Message: 2 Date: Sat, 16 Apr 2016 02:36:31 +0200 From: Simon Jakobi <simon.jak...@googlemail.com> To: The Haskell-Beginners Mailing List - Discussion of primarily beginner-level topics related to Haskell <beginners@haskell.org>, gm...@otterhall.com Subject: Re: [Haskell-beginners] Trying to install "Craft3e" from Hackage using stack Message-ID: <CAGtp2SgHNscFW5SnTYU9aJEWx=BbO=xpfo4xey13otbk1pe...@mail.gmail.com> Content-Type: text/plain; charset=UTF-8 Assuming that you would keep any book-related code in a local project, here's how you'd create a local project with a dependency on Craft3e: # Create a new project using ghc-7.8 (due to Craft3e's dependency on mtl <2.2) $ stack --resolver ghc-7.8 new craft $ cd craft # Edit the library section of craft.cabal to contain a dependency on Craft3e: # # build-depends: base >= 4.7 && < 5 # , Craft3e # # Calculate a consistent set of packages to use in the project: $ stack solver --update-config Now you can write exercises etc. as library modules in the src directory and use them interactively with stack repl. If you haven't used stack before, you might also want to take a look at the stack guide: http://docs.haskellstack.org/en/stable/GUIDE/ Cheers, Simon ------------------------------ Message: 3 Date: Sat, 16 Apr 2016 10:28:07 +0200 From: Albin Otterh?ll <gm...@otterhall.com> To: beginners@haskell.org Subject: Re: [Haskell-beginners] Trying to install "Craft3e" from Hackage using stack Message-ID: <nest33$ifq$1...@ger.gmane.org> Content-Type: text/plain; charset=windows-1252 On 2016-04-16 02:36, Simon Jakobi wrote: > Assuming that you would keep any book-related code in a local project, > here's how you'd create a local project with a dependency on Craft3e: > > # Create a new project using ghc-7.8 (due to Craft3e's dependency on mtl <2.2) > $ stack --resolver ghc-7.8 new craft > $ cd craft > # Edit the library section of craft.cabal to contain a dependency on Craft3e: > # > # build-depends: base >= 4.7 && < 5 > # , Craft3e > # > # Calculate a consistent set of packages to use in the project: > $ stack solver --update-config > > Now you can write exercises etc. as library modules in the src > directory and use them interactively with stack repl. > > If you haven't used stack before, you might also want to take a look > at the stack guide: > http://docs.haskellstack.org/en/stable/GUIDE/ > > Cheers, > Simon > I don't know if it's possible with the method you described, but I need to be able to import some files into GHCi. They contain function definitions that I have to be able to use in GHCi. Regards, Albin ------------------------------ Subject: Digest Footer _______________________________________________ Beginners mailing list Beginners@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners ------------------------------ End of Beginners Digest, Vol 94, Issue 13 *****************************************