1. 6

  2. 6


    #!/usr/bin/env stack
    {- stack script
       --resolver lts-11.6
       --package protolude
    {-# LANGUAGE NoImplicitPrelude #-}
    {-# LANGUAGE OverloadedStrings #-}
    import Protolude
    main = putText "Hello, world!"
    1. 5

      Excuse me, have you heard about our lord and savior nix?

      More seriously, the Haskell build environment is clearly a problem. I tried using a stackage nix overlay for a while, it was quite a long setup, and having to rebuild the entire package for each update was too much demanding for my 7-year-old computer. I saw some bazel-based setups but haven’t tried myself…

      Stackage is really great, but I agree the stack tool could be more user friendly. But in the end, I still use stack and have to delete randomly my .stack directory every once in a while.

      Rants are usually fun, but we could also talk what makes the racket build-system great and see how we could transpose that and slowly derive to a similar system.

      [Edit] BTW, cabal != cabal-install. “ I came to Stack to avoid Cabal.” => stack actually use cabal.

      1. 1

        I thought stack is invented to avoid cabal install, it’s the same as ruby’s gem install vs bundle (which uses gem internally). So i’m not sure what are use cases for stack install.

        Nix is the same bundler, but for system-level packages, which is great and unifying, but I don’t understand why use it if your project and its dependencies are mostly in haskell.

      2. 1

        I can’t use Haskell simply because GHC is too slow on my 12” MacBook. It’s the only compiler that makes development in the respective language impossible on this machine. 😕