
Stack – a Haskell development tool - rev
https://www.fpcomplete.com/blog/2015/06/announcing-first-public-beta-stack
======
deckiedan
This looks pretty cool - I hope it works. I couldn't download the ubuntu
package, as download.fpcomplete.com is unreachable here. I downloaded the
linux-generic package, but it seems to be a bit older, and so doesn't cope w/o
a stack.yaml file.

OK - now with a stack.yaml file it's busy getting me a ghci...

cabal hell was one of the first things that really put me off haskell. I was
downloading and trying to get xmonad working, but within half an hour, had a
completely unusable ghc / xmonad combination. I think I was on debian, and the
version of ghc that was installed wasn't compatible with the correct versions
of various libs that xmonad wanted to have installed... Very frustrating.

Well, looks like installing stack does at least allow me to get a ghci up and
running. That's cool. The easier getting haskell up and running becomes, the
better. It's a wacky and esoteric language enough without it being hard to get
going...

Interesting how programming languages "need" their own package manager these
days. A bit of a pain that there's no universal one for all languages, but I
guess that would be just too convenient...

~~~
davexunit
>A bit of a pain that there's no universal one for all languages, but I guess
that would be just too convenient...

Nix and GNU Guix are capable of filling this role. Not only can they do the
things that the typical system package managers (dpkg, yum) lack, but they
also do many things that language-specific package managers lack.
Transactional upgrades, rollbacks, unprivileged package installation,
gracefully handling multiple versions of the same software, system-wide
deduplication, full system configuration (if you want to use their associated
distro), etc.

I have read several Nix + Haskell success stories on various blogs, so I would
say it's worth checking out. Nix and Guix are the future of package
management.

~~~
chriswarbo
Nix is pretty great.

Something to be aware of for Haskell: Nix's Haskell infrastructure has gone
through a big breaking change recently. It's settled down now, and the new
system (AKA "haskell NG") is much nicer, but all of the "stable" releases are
using the old system, and a lot of blog posts, etc. online are now out of
date.

~~~
cr__
Do you have any links on how the new system is supposed to work? I'm trying to
piece it together and I'm not having much luck.

~~~
loevborg
As I understand it, the corresponding section of the nixpkgs manual is being
written as we speak; when this is done, it should reflect the new haskell
infrastructure which was merged a few months ago (no longer called haskell-ng
any more btw). In the meantime, here are a few links to get you started:

[https://twitter.com/garbas/status/601717689225187328](https://twitter.com/garbas/status/601717689225187328)
\-- a recent presentation w/ accompanying slides introducing Nix's new haskell
infrastructure by github.com/peti, the maintainer

[https://nixos.org/wiki/Haskell](https://nixos.org/wiki/Haskell)

[http://wiki.ocharles.org.uk/Nix](http://wiki.ocharles.org.uk/Nix)

[http://stackoverflow.com/questions/29033580/how-do-i-use-
the...](http://stackoverflow.com/questions/29033580/how-do-i-use-the-new-
haskell-ng-infrastructure-on-nixos)

~~~
cr__
The ocharles link is exactly what I'm looking for. Thanks so much.

------
tyilo
Hmm...

    
    
      $ cabal install stack
      Resolving dependencies...
      Configuring stack-0.0.1...
      Building stack-0.0.1...
      Failed to install stack-0.0.1
      Build log ( /Users/Tyilo/.cabal/logs/stack-0.0.1.log ):
      Configuring stack-0.0.1...
      Building stack-0.0.1...
      Preprocessing library stack-0.0.1...
      ...
      [45 of 45] Compiling Stack.Config     ( src/Stack/Config.hs, dist/build/Stack/Config.o )
      ghc: panic! (the 'impossible' happened)
        (GHC version 7.10.1 for x86_64-apple-darwin):
      	Loading temp shared object failed: dlopen(/var/folders/db/kt60mzx93p110r61jzjbf3nw0000gn/T/ghc19215_0/libghc19215_228.dylib, 5): Symbol not found: _stackzuIf4F8EsotzzFA5770kfJV6V_StackziTypesziFlagName_zdfBinaryFlagName_closure
        Referenced from: /var/folders/db/kt60mzx93p110r61jzjbf3nw0000gn/T/ghc19215_0/libghc19215_228.dylib
        Expected in: flat namespace
       in /var/folders/db/kt60mzx93p110r61jzjbf3nw0000gn/T/ghc19215_0/libghc19215_228.dylib
      
      Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug
      
      cabal: Error: some packages failed to install:
      stack-0.0.1 failed during the building phase. The exception was:
      ExitFailure 1

~~~
reagency
The earlier you see failure, the luckier you are. The haskellverse is jammed
packed with popular packages that won't build and run properly on your
platform.

Nothing quite works except for small toy projects and Haskell +systems whizzes
who can dig into native platform arcana.

~~~
codygman
> The haskellverse is jammed packed with popular packages that won't build and
> run properly on your platform

This tool is aimed at fixing that, ironically the GP used cabal in an attempt
to install a tool fixing cabals problems.

> Nothing quite works except for small toy projects and Haskell +systems
> whizzes who can dig into native platform arcana.

Not true. Did you have a bad experience building a Haskell package for a
specific platform in the past? Stack might let you install it all seamlessly,
you should give it a try :)

I recommend installing one of their binaries though:
[https://github.com/commercialhaskell/stack/wiki/Downloads](https://github.com/commercialhaskell/stack/wiki/Downloads)

------
Simpliplant
How anybody give some good comparison with Halcyon?

~~~
mietek
Halcyon author here. Here’s a couple of my thoughts:

[http://www.reddit.com/r/haskell/comments/3957e1/announcing_f...](http://www.reddit.com/r/haskell/comments/3957e1/announcing_first_public_beta_of_stack/cs0ok3y?context=4)

------
codygman
Getting a 502 error when trying to add fpco.key. Guessing servers are
overloaded?

~~~
borsboom
Looks like there was a typo in the download links for Ubuntu 15.04. I've just
fixed them, so please try again.

------
x5n1
Are there any examples of Haskell being used to do anything really cool and
useful to the average programmer. To me it seems as an esoteric language that
I would simply not bother using because no one uses it and deploying it would
be a headache.

~~~
akurilin
We use Haskell for most of our backend (and hopefully frontend soon) work at
Front Row: [http://www.kurilin.net/post/117369543198/haskell-at-front-
ro...](http://www.kurilin.net/post/117369543198/haskell-at-front-row)

~~~
qbit
If you don't mind answering, which Haskell frontend are you planning to use?

~~~
akurilin
I'm hoping that we can find a GHCJS-based FRP solution at some point soon.
I've seen Elm in action, and it's pretty neat, same with Purescript, but I'd
rather stay _within_ legitimate Haskell for the time being.

~~~
codygman
> I'm hoping that we can find a GHCJS-based FRP solution at some point soon.

Have you tried Reflex (also there is a try-reflex[1])?

Purescript generates really concise javascript code, have you checked out
Thermite[2]?

0:
[https://github.com/ryantrinkle/reflex](https://github.com/ryantrinkle/reflex)
1: [https://github.com/ryantrinkle/try-
reflex](https://github.com/ryantrinkle/try-reflex) 2:
[https://github.com/paf31/purescript-
thermite](https://github.com/paf31/purescript-thermite)

