New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GHCJS? #337

Closed
jkozlowski opened this Issue Jun 17, 2015 · 97 comments

Comments

Projects
None yet
@jkozlowski

jkozlowski commented Jun 17, 2015

Are there plans to support GHCJS in the same first class way as GHC (i.e. getting the binaries etc.)?

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg Jun 17, 2015

Contributor

Not yet, but I like the idea. Let's use this issue as a discussion point for it.

Contributor

snoyberg commented Jun 17, 2015

Not yet, but I like the idea. Let's use this issue as a discussion point for it.

@snoyberg snoyberg added this to the Later improvements milestone Jun 17, 2015

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jun 17, 2015

Thanks for a quick reply. I already saw some calls for better distribution on the ghcjs github (ghcjs/ghcjs#231). I think if it would be just as painless to get ghcjs through stack as it is ghc (including getting ghcjs packages from stackage) it would greatly help with adoption.

jkozlowski commented Jun 17, 2015

Thanks for a quick reply. I already saw some calls for better distribution on the ghcjs github (ghcjs/ghcjs#231). I think if it would be just as painless to get ghcjs through stack as it is ghc (including getting ghcjs packages from stackage) it would greatly help with adoption.

@cocreature

This comment has been minimized.

Show comment
Hide comment
@cocreature

cocreature Jun 17, 2015

Contributor

Just to show that there's interest: I'm interested :)

Contributor

cocreature commented Jun 17, 2015

Just to show that there's interest: I'm interested :)

@bitemyapp

This comment has been minimized.

Show comment
Hide comment
@bitemyapp

bitemyapp Jun 17, 2015

Contributor

This hinges in part on GHC 7.10 compatibility does it not?

Contributor

bitemyapp commented Jun 17, 2015

This hinges in part on GHC 7.10 compatibility does it not?

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Jun 17, 2015

Collaborator

Nah, GHCJS works fine with 7.8.4. Infact I've found it more of a challenge to boot it with 7.10. I didn't realize there were compatibility issues with 7.10? (though further discussion of that should go in a different issue, if one doesn't already exist)

Anyway, agreed that this would be a nice thing to have! It's particularly useful when sharing code between the client and server. Currently I need to remember to run my ghcjs build script, and otherwise the protocol types can go out of sync.

Collaborator

mgsloan commented Jun 17, 2015

Nah, GHCJS works fine with 7.8.4. Infact I've found it more of a challenge to boot it with 7.10. I didn't realize there were compatibility issues with 7.10? (though further discussion of that should go in a different issue, if one doesn't already exist)

Anyway, agreed that this would be a nice thing to have! It's particularly useful when sharing code between the client and server. Currently I need to remember to run my ghcjs build script, and otherwise the protocol types can go out of sync.

@bitemyapp

This comment has been minimized.

Show comment
Hide comment
@bitemyapp

bitemyapp Jun 17, 2015

Contributor

Having an ez-pz way to get people going with GHCJS would be wonderful.

Contributor

bitemyapp commented Jun 17, 2015

Having an ez-pz way to get people going with GHCJS would be wonderful.

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jun 17, 2015

This hinges in part on GHC 7.10 compatibility does it not?

GHCJS compatiblity? Granted that it's on a branch, but I am running on 7.10 fine (https://github.com/ghcjs/ghcjs/wiki/GHCJS-with-GHC-7.10)

jkozlowski commented Jun 17, 2015

This hinges in part on GHC 7.10 compatibility does it not?

GHCJS compatiblity? Granted that it's on a branch, but I am running on 7.10 fine (https://github.com/ghcjs/ghcjs/wiki/GHCJS-with-GHC-7.10)

@bitemyapp

This comment has been minimized.

Show comment
Hide comment
@bitemyapp

bitemyapp Jun 18, 2015

Contributor

@jkozlowski I thought Stack was GHC 7.8 only and didn't know GHCJS worked with 7.8

Contributor

bitemyapp commented Jun 18, 2015

@jkozlowski I thought Stack was GHC 7.8 only and didn't know GHCJS worked with 7.8

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jun 18, 2015

So, would the first step be to get binary builds setup somewhere/somehow? I don't know if FP Complete already does that somehow, or it exists somewhere else (no official ones, according to my issue on ghcjs github).

jkozlowski commented Jun 18, 2015

So, would the first step be to get binary builds setup somewhere/somehow? I don't know if FP Complete already does that somehow, or it exists somewhere else (no official ones, according to my issue on ghcjs github).

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg Jun 19, 2015

Contributor

We do already have Docker images with ghcjs binaries. Another option is just automating the process of building ghcjs

Contributor

snoyberg commented Jun 19, 2015

We do already have Docker images with ghcjs binaries. Another option is just automating the process of building ghcjs

@krisajenkins

This comment has been minimized.

Show comment
Hide comment
@krisajenkins

krisajenkins Jun 19, 2015

+1! Stack has now addressed every problem I have with Haskell adoption, save this one. I'm using Elm for frontend stuff, but I'm using it at its limits and would love to use GHCJS if you could work your supermagic on the install-process. :-)

krisajenkins commented Jun 19, 2015

+1! Stack has now addressed every problem I have with Haskell adoption, save this one. I'm using Elm for frontend stuff, but I'm using it at its limits and would love to use GHCJS if you could work your supermagic on the install-process. :-)

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Jun 19, 2015

Collaborator

It'll be awesome to have full stack support for GHCJS in the future. However, for now stack's docker images do help a ton to make it easy to do development on GHCJS. Here's what I'm using for the new School of Haskell:

Have something like this in your stack.yaml:

resolver: lts-2.14
docker:
  enable: true
  repo: fpco/stack-ghcjs-build

fpco/stack-ghcjs-build is a ~4.5gb or so image, which doesn't have all of stackage installed. If you want that, there's a 16GB image with all of stackage at fpco/stack-ghcjs-full. Other images are here.

Then, you can do this to build and install ghcjs dependencies:

stack exec -- cabal --config-file=cabal-ghcjs-config update
stack exec -- cabal --config-file=cabal-ghcjs-config install --ghcjs all-the-ghcjs-stuff-i-want/ to-install/

Why the --config-file=cabal-ghcjs-config? I found it to be necessary in order to avoid dependency issues. For simpler usecases it might be fine to omit, though. This causes a new config file to be initialized and used by ghcjs, instead of using the global stackage config file used by cabal. This isn't perfect, because it means the packages shared by your server and client could have different versions. For example, you might end up with a different version of aeson than is in the stackage snapshot.

Collaborator

mgsloan commented Jun 19, 2015

It'll be awesome to have full stack support for GHCJS in the future. However, for now stack's docker images do help a ton to make it easy to do development on GHCJS. Here's what I'm using for the new School of Haskell:

Have something like this in your stack.yaml:

resolver: lts-2.14
docker:
  enable: true
  repo: fpco/stack-ghcjs-build

fpco/stack-ghcjs-build is a ~4.5gb or so image, which doesn't have all of stackage installed. If you want that, there's a 16GB image with all of stackage at fpco/stack-ghcjs-full. Other images are here.

Then, you can do this to build and install ghcjs dependencies:

stack exec -- cabal --config-file=cabal-ghcjs-config update
stack exec -- cabal --config-file=cabal-ghcjs-config install --ghcjs all-the-ghcjs-stuff-i-want/ to-install/

Why the --config-file=cabal-ghcjs-config? I found it to be necessary in order to avoid dependency issues. For simpler usecases it might be fine to omit, though. This causes a new config file to be initialized and used by ghcjs, instead of using the global stackage config file used by cabal. This isn't perfect, because it means the packages shared by your server and client could have different versions. For example, you might end up with a different version of aeson than is in the stackage snapshot.

@luite

This comment has been minimized.

Show comment
Hide comment
@luite

luite Jun 19, 2015

How important is it to have 7.8 compatibility in GHCJS? I'm working on putting together a release, based on the improved-base branch, but this currently only has 7.10 compatibility. Dropping 7.8 saves a bit of maintenance (different set of boot packages, and some API's in GHC have been improved in 7.10), but it's not impossible to support it a bit longer.

The 7.10.2 release candidate works fine by the way, no workarounds needed anymore.

luite commented Jun 19, 2015

How important is it to have 7.8 compatibility in GHCJS? I'm working on putting together a release, based on the improved-base branch, but this currently only has 7.10 compatibility. Dropping 7.8 saves a bit of maintenance (different set of boot packages, and some API's in GHC have been improved in 7.10), but it's not impossible to support it a bit longer.

The 7.10.2 release candidate works fine by the way, no workarounds needed anymore.

@krisajenkins

This comment has been minimized.

Show comment
Hide comment
@krisajenkins

krisajenkins Jun 19, 2015

Doesn't matter to me at all. I'd like to move everything to 7.10. #onevote

krisajenkins commented Jun 19, 2015

Doesn't matter to me at all. I'd like to move everything to 7.10. #onevote

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jun 19, 2015

@mgsloan You workflow sounds like a nice workaround, I'll give it a try this weekend if I find some time. I am currently just using a hand built ghcjs that was built into a sandbox.

But also if it already is possible, maybe just automating those steps (with the caveats that it pulls in a massive docker image) would be already a step in the right direction. Just a thought/

jkozlowski commented Jun 19, 2015

@mgsloan You workflow sounds like a nice workaround, I'll give it a try this weekend if I find some time. I am currently just using a hand built ghcjs that was built into a sandbox.

But also if it already is possible, maybe just automating those steps (with the caveats that it pulls in a massive docker image) would be already a step in the right direction. Just a thought/

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg Jun 19, 2015

Contributor

@luite I'm definitely OK with the release with only 7.10.2 support. Want to touch base next week about figuring out a good release strategy that could give stack users easy access to GHCJS?

Contributor

snoyberg commented Jun 19, 2015

@luite I'm definitely OK with the release with only 7.10.2 support. Want to touch base next week about figuring out a good release strategy that could give stack users easy access to GHCJS?

@luite

This comment has been minimized.

Show comment
Hide comment
@luite

luite Jun 19, 2015

Sure. I just returned from travels and I'm dedicating some time the coming weeks to finally sort out the long standing issues and get a release out of the door.

luite commented Jun 19, 2015

Sure. I just returned from travels and I'm dedicating some time the coming weeks to finally sort out the long standing issues and get a release out of the door.

@cstrahan

This comment has been minimized.

Show comment
Hide comment
@cstrahan

cstrahan Jun 19, 2015

@bitemyapp: Having an ez-pz way to get people going with GHCJS would be wonderful.

One option would be Nix :). Yes, Nix has it's own learning curve, but one can ignore most of it if all they want/need to do is get ghcjs installed. @ryantrinkle provides a script to automate the install of Nix and ghcjs, and uninstalling is as easy as rm -rf /nix.

cstrahan commented Jun 19, 2015

@bitemyapp: Having an ez-pz way to get people going with GHCJS would be wonderful.

One option would be Nix :). Yes, Nix has it's own learning curve, but one can ignore most of it if all they want/need to do is get ghcjs installed. @ryantrinkle provides a script to automate the install of Nix and ghcjs, and uninstalling is as easy as rm -rf /nix.

@krisajenkins

This comment has been minimized.

Show comment
Hide comment
@krisajenkins

krisajenkins Jun 24, 2015

FWIW, Nix (on OSX) defeated me. I'm still hoping for stack to nail it. Plus, I don't think I could recommend Nix to someone who just wants to get started with Haskell, the way I feel I could recommend stack. That alone is priceless.

krisajenkins commented Jun 24, 2015

FWIW, Nix (on OSX) defeated me. I'm still hoping for stack to nail it. Plus, I don't think I could recommend Nix to someone who just wants to get started with Haskell, the way I feel I could recommend stack. That alone is priceless.

@luite

This comment has been minimized.

Show comment
Hide comment
@luite

luite Jun 24, 2015

With GHC 7.10.2 (release candidate), installation from source should actually become doable for mere mortals (but packages may still be preferred due to the build time and setup of dependencies). I'm readying the improved-base branch for release, installation goes like:

http://lpaste.net/135131

And there's a script for Windows that builds everything from source on a clean Windows installation:

https://github.com/ghcjs/ghcjs/blob/improved-base/utils/install.ps1

Ooh and and what's this? A REPL?

luite@Luites-MacBook-Pro:~/ghcjs/ghcjs$ ghcjs --interactive
GHCJSi, version 0.1.0-7.10.1.20150612: http://www.github.com/ghcjs/ghcjs/  :? for help
Prelude> let x = 5
Prelude> let y = x
Prelude> let x = 6
Prelude> x + y
11

Prelude> foreign import javascript unsafe "Math.sin($1)" js_sin :: Double -> Double
Prelude> js_sin x
-0.27941549819892586

Prelude> 

(See WIP in ghcjsi branch)

luite commented Jun 24, 2015

With GHC 7.10.2 (release candidate), installation from source should actually become doable for mere mortals (but packages may still be preferred due to the build time and setup of dependencies). I'm readying the improved-base branch for release, installation goes like:

http://lpaste.net/135131

And there's a script for Windows that builds everything from source on a clean Windows installation:

https://github.com/ghcjs/ghcjs/blob/improved-base/utils/install.ps1

Ooh and and what's this? A REPL?

luite@Luites-MacBook-Pro:~/ghcjs/ghcjs$ ghcjs --interactive
GHCJSi, version 0.1.0-7.10.1.20150612: http://www.github.com/ghcjs/ghcjs/  :? for help
Prelude> let x = 5
Prelude> let y = x
Prelude> let x = 6
Prelude> x + y
11

Prelude> foreign import javascript unsafe "Math.sin($1)" js_sin :: Double -> Double
Prelude> js_sin x
-0.27941549819892586

Prelude> 

(See WIP in ghcjsi branch)

@ghost

This comment has been minimized.

Show comment
Hide comment
@ghost

ghost Jun 24, 2015

@luite AHHH Must Have!

Presently only able to build using the Nix script provided by @ryantrinkle and am eagerly awaiting a 'push button' install.

ghost commented Jun 24, 2015

@luite AHHH Must Have!

Presently only able to build using the Nix script provided by @ryantrinkle and am eagerly awaiting a 'push button' install.

@mmaz

This comment has been minimized.

Show comment
Hide comment
@mmaz

mmaz Jun 24, 2015

@luite that branch is unbelievably exciting! If in the future, emacs-haskell-mode could plumb through toghcjsi automatically by invoking stack ghc for GHCJS projects, that would be an incredible development environment!

mmaz commented Jun 24, 2015

@luite that branch is unbelievably exciting! If in the future, emacs-haskell-mode could plumb through toghcjsi automatically by invoking stack ghc for GHCJS projects, that would be an incredible development environment!

@joelburget

This comment has been minimized.

Show comment
Hide comment
@joelburget

joelburget Jun 25, 2015

Big +1. Exciting stuff :)

joelburget commented Jun 25, 2015

Big +1. Exciting stuff :)

@CRogers

This comment has been minimized.

Show comment
Hide comment
@CRogers

CRogers Jun 25, 2015

Contributor

Something I'm interested in is having support for mixing ghcjs and ghc projects. For example, I often want to have something like:

  • A client project compiled with ghcjs
  • A server project compiled with ghc
  • A library with shared code that gets compiled with both ghc and ghcjs

Some way to have this just work with stack would be great.

@luite GHCJSi is super exciting :D

Contributor

CRogers commented Jun 25, 2015

Something I'm interested in is having support for mixing ghcjs and ghc projects. For example, I often want to have something like:

  • A client project compiled with ghcjs
  • A server project compiled with ghc
  • A library with shared code that gets compiled with both ghc and ghcjs

Some way to have this just work with stack would be great.

@luite GHCJSi is super exciting :D

@manyoo

This comment has been minimized.

Show comment
Hide comment
@manyoo

manyoo Jun 25, 2015

+1 ! I’m currently starting working on such a project. Before stack, I tried to use cabal sandbox, but when compiling ghcjs code, it can’t find the ghcjs packages like ghcjs-base installed in the global ghcjs package directory. Now, I’ve removed the cabal sandbox, and use stack for server side ghc code, and cabal with no sandbox for client side ghcjs code. If stack can make it easy to work in such setup, it would be really awesome!

Eric Wong
Professional Web Developer.

On Jun 25, 2015, at 2:55 PM, Callum Rogers notifications@github.com wrote:

Something I'm interested in is having support for a mixing ghcjs and ghc projects. For example, I often want to have something like:

A client project compiled with ghcjs
A server project compiled with ghc
A library with shared code that gets compile with both ghc and ghcjs
Some way to have this just work with stack would be great.

@luite https://github.com/luite GHCJSi is super exciting :D


Reply to this email directly or view it on GitHub #337 (comment).

manyoo commented Jun 25, 2015

+1 ! I’m currently starting working on such a project. Before stack, I tried to use cabal sandbox, but when compiling ghcjs code, it can’t find the ghcjs packages like ghcjs-base installed in the global ghcjs package directory. Now, I’ve removed the cabal sandbox, and use stack for server side ghc code, and cabal with no sandbox for client side ghcjs code. If stack can make it easy to work in such setup, it would be really awesome!

Eric Wong
Professional Web Developer.

On Jun 25, 2015, at 2:55 PM, Callum Rogers notifications@github.com wrote:

Something I'm interested in is having support for a mixing ghcjs and ghc projects. For example, I often want to have something like:

A client project compiled with ghcjs
A server project compiled with ghc
A library with shared code that gets compile with both ghc and ghcjs
Some way to have this just work with stack would be great.

@luite https://github.com/luite GHCJSi is super exciting :D


Reply to this email directly or view it on GitHub #337 (comment).

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jun 25, 2015

+1 that would be perfect.

jkozlowski commented Jun 25, 2015

+1 that would be perfect.

@cdepillabout

This comment has been minimized.

Show comment
Hide comment
@cdepillabout

cdepillabout Jun 25, 2015

Member

@luite: let me join in and say that I'm excited about ghcjs and ghc-7.10.2.

@CRogers: that's the exact same setup that I would be envisioning.

Member

cdepillabout commented Jun 25, 2015

@luite: let me join in and say that I'm excited about ghcjs and ghc-7.10.2.

@CRogers: that's the exact same setup that I would be envisioning.

@luite

This comment has been minimized.

Show comment
Hide comment
@luite

luite Jun 25, 2015

Just a quick heads-up: As from the latest commit, GHCJSi supports evaluating code in the browser. Just npm install -g socket.io first (and don't forget to set NODE_PATH) and go to http://localhost:6400 after starting GHCJSi, before running any code. This gives you DOM access and should open up new fun ways to experiment and interact with Haskell and JS libraries. I've also fixed loading Haskell modules from disk (cabal repl works now out of the box) and declarations in the REPL.

http://hdiff.luite.com/tmp/ghcjsi1.png

But I'm going back to preparing the libraries and release now, after recovering from a four-day GHCJSi code-binge. It's quite addictive! GHCJSi is far from production ready, so it's not going to be in the next release, but it's definitely coming.

luite commented Jun 25, 2015

Just a quick heads-up: As from the latest commit, GHCJSi supports evaluating code in the browser. Just npm install -g socket.io first (and don't forget to set NODE_PATH) and go to http://localhost:6400 after starting GHCJSi, before running any code. This gives you DOM access and should open up new fun ways to experiment and interact with Haskell and JS libraries. I've also fixed loading Haskell modules from disk (cabal repl works now out of the box) and declarations in the REPL.

http://hdiff.luite.com/tmp/ghcjsi1.png

But I'm going back to preparing the libraries and release now, after recovering from a four-day GHCJSi code-binge. It's quite addictive! GHCJSi is far from production ready, so it's not going to be in the next release, but it's definitely coming.

@CRogers

This comment has been minimized.

Show comment
Hide comment
@CRogers

CRogers Jun 25, 2015

Contributor

GHCJSi supports evaluating code in the browser

That is incredibly exciting - I never even imagined you'd be able to do
that!

On Thu, 25 Jun 2015 13:56 Luite Stegeman notifications@github.com wrote:

Just a quick heads-up: As from the latest commit, GHCJSi supports
evaluating code in the browser. Just npm install -g socket.io first (and
don't forget to set NODE_PATH) and go to http://localhost:6400 after
starting GHCJSi, before running any code. This gives you DOM access and
should open up new fun ways to experiment and interact with Haskell and JS
libraries. I've also fixed loading Haskell modules from disk (cabal repl
works now out of the box) and declarations in the REPL.

http://hdiff.luite.com/tmp/ghcjsi1.png

But I'm going back to preparing the libraries and release now, after
recovering from a four-day GHCJSi code-binge. It's quite addictive! GHCJSi
is far from production ready, so it's not going to be in the next release,
but it's definitely coming.


Reply to this email directly or view it on GitHub
#337 (comment)
.

Contributor

CRogers commented Jun 25, 2015

GHCJSi supports evaluating code in the browser

That is incredibly exciting - I never even imagined you'd be able to do
that!

On Thu, 25 Jun 2015 13:56 Luite Stegeman notifications@github.com wrote:

Just a quick heads-up: As from the latest commit, GHCJSi supports
evaluating code in the browser. Just npm install -g socket.io first (and
don't forget to set NODE_PATH) and go to http://localhost:6400 after
starting GHCJSi, before running any code. This gives you DOM access and
should open up new fun ways to experiment and interact with Haskell and JS
libraries. I've also fixed loading Haskell modules from disk (cabal repl
works now out of the box) and declarations in the REPL.

http://hdiff.luite.com/tmp/ghcjsi1.png

But I'm going back to preparing the libraries and release now, after
recovering from a four-day GHCJSi code-binge. It's quite addictive! GHCJSi
is far from production ready, so it's not going to be in the next release,
but it's definitely coming.


Reply to this email directly or view it on GitHub
#337 (comment)
.

@alexanderkjeldaas

This comment has been minimized.

Show comment
Hide comment
@alexanderkjeldaas

alexanderkjeldaas Jun 27, 2015

Contributor

+1 just posting my interest in stack+ghcjs. I do not care about 7.8 vs 7.10.

Contributor

alexanderkjeldaas commented Jun 27, 2015

+1 just posting my interest in stack+ghcjs. I do not care about 7.8 vs 7.10.

@vikasmenon

This comment has been minimized.

Show comment
Hide comment
@vikasmenon

vikasmenon Jun 27, 2015

+1. This would be neat.

vikasmenon commented Jun 27, 2015

+1. This would be neat.

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jun 29, 2015

@snoyberg and @luite: did you guys manage to agree on something?

jkozlowski commented Jun 29, 2015

@snoyberg and @luite: did you guys manage to agree on something?

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg Jun 29, 2015

Contributor

I just spoke with @mgsloan about this actually. He's been working on some code recently using GHCJS and stack, so he has a better feel for the requirements than I do. I haven't yet touched base with Luite unfortunately.

Contributor

snoyberg commented Jun 29, 2015

I just spoke with @mgsloan about this actually. He's been working on some code recently using GHCJS and stack, so he has a better feel for the requirements than I do. I haven't yet touched base with Luite unfortunately.

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski Jul 2, 2015

@mgsloan: I only just tried your workaround, and got:
WARNING: Using boot2docker is NOT supported, and not likely to perform well. and then a bunch of errors. So I guess the docker support is not full on Mac OS X.

jkozlowski commented Jul 2, 2015

@mgsloan: I only just tried your workaround, and got:
WARNING: Using boot2docker is NOT supported, and not likely to perform well. and then a bunch of errors. So I guess the docker support is not full on Mac OS X.

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg Jul 2, 2015

Contributor

@jkozlowski I believe that's currently the case, but it's being worked on. I'd suggest we move the Docker discussion though to a different issue, I'm sure @manny-fp will have some advice since he uses our Docker support on Mac OS X regularly.

Contributor

snoyberg commented Jul 2, 2015

@jkozlowski I believe that's currently the case, but it's being worked on. I'd suggest we move the Docker discussion though to a different issue, I'm sure @manny-fp will have some advice since he uses our Docker support on Mac OS X regularly.

@jkozlowski

This comment has been minimized.

Show comment
Hide comment
@jkozlowski

jkozlowski commented Jul 2, 2015

Thanks.

@bitemyapp

This comment has been minimized.

Show comment
Hide comment
@bitemyapp

bitemyapp Oct 2, 2015

Contributor

@vertexcite @fizruk thank you both for sharing these, this is very helpful!

Contributor

bitemyapp commented Oct 2, 2015

@vertexcite @fizruk thank you both for sharing these, this is very helpful!

@GetContented

This comment has been minimized.

Show comment
Hide comment
@GetContented

GetContented Oct 3, 2015

@fizruk could you create a wiki page for it?

GetContented commented Oct 3, 2015

@fizruk could you create a wiki page for it?

@fizruk

This comment has been minimized.

Show comment
Hide comment
@fizruk

fizruk Oct 3, 2015

Contributor

@GetContented I have now created a wike page for Stack & GHCJS.

Contributor

fizruk commented Oct 3, 2015

@GetContented I have now created a wike page for Stack & GHCJS.

@GetContented

This comment has been minimized.

Show comment
Hide comment
@GetContented

GetContented commented Oct 3, 2015

@fizruk Thank you :)

@xavier83

This comment has been minimized.

Show comment
Hide comment
@xavier83

xavier83 Oct 3, 2015

@fizruk awesome. Thanks 👍

xavier83 commented Oct 3, 2015

@fizruk awesome. Thanks 👍

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 3, 2015

Collaborator

@fizruk Good stuff, thanks! Most of it's spot on, I've updated with some more info and a correction for the versions (stack setup isn't supported by any released version of GHCJS).

Collaborator

mgsloan commented Oct 3, 2015

@fizruk Good stuff, thanks! Most of it's spot on, I've updated with some more info and a correction for the versions (stack setup isn't supported by any released version of GHCJS).

@dredozubov

This comment has been minimized.

Show comment
Hide comment
@dredozubov

dredozubov Oct 12, 2015

Contributor

Looking forward for it in the next release! It'll be extremely useful.

Contributor

dredozubov commented Oct 12, 2015

Looking forward for it in the next release! It'll be extremely useful.

@k-bx

This comment has been minimized.

Show comment
Hide comment
@k-bx

k-bx Oct 12, 2015

Contributor

@fizruk can you take a look please?

$ cat stack.yaml
resolver: ghcjs-0.2.0.20151001_ghc-7.10.2
compiler-check: match-exact
setup-info:
  ghcjs:
    source:
      ghcjs-0.2.0.20151001_ghc-7.10.2:
        url: "https://github.com/fizruk/ghcjs/releases/download/v0.2.0.20151001/ghcjs-0.2.0.20151001.tar.gz"

packages:
- '.'
$ stack setup
Warning: /Users/kb/workspace/ghcjs-stack-play/stack.yaml: Unrecognized field in SetupInfo: ghcjs
Warning: https://raw.githubusercontent.com/fpco/stackage-content/master/stack/stack-setup-2.yaml: Unrecognized field in SetupInfo: ghcjs
No information found for ghcjs-0.2.0.20151001_ghc-7.10.2.
Supported versions for OS key 'macosx': 7.8.4, 7.10.1, 7.10.2
$ stack --version
Version 0.1.5.0 X86_64
Contributor

k-bx commented Oct 12, 2015

@fizruk can you take a look please?

$ cat stack.yaml
resolver: ghcjs-0.2.0.20151001_ghc-7.10.2
compiler-check: match-exact
setup-info:
  ghcjs:
    source:
      ghcjs-0.2.0.20151001_ghc-7.10.2:
        url: "https://github.com/fizruk/ghcjs/releases/download/v0.2.0.20151001/ghcjs-0.2.0.20151001.tar.gz"

packages:
- '.'
$ stack setup
Warning: /Users/kb/workspace/ghcjs-stack-play/stack.yaml: Unrecognized field in SetupInfo: ghcjs
Warning: https://raw.githubusercontent.com/fpco/stackage-content/master/stack/stack-setup-2.yaml: Unrecognized field in SetupInfo: ghcjs
No information found for ghcjs-0.2.0.20151001_ghc-7.10.2.
Supported versions for OS key 'macosx': 7.8.4, 7.10.1, 7.10.2
$ stack --version
Version 0.1.5.0 X86_64
@kfigiela

This comment has been minimized.

Show comment
Hide comment
@kfigiela

kfigiela Oct 12, 2015

@k-bx: you need to stack upgrade --git. Make sure that you have Cabal library version 1.22.4 installed (my coleague had 1.22.2 and then ghcjs-boot phase failed, maybe stack could check that?)

kfigiela commented Oct 12, 2015

@k-bx: you need to stack upgrade --git. Make sure that you have Cabal library version 1.22.4 installed (my coleague had 1.22.2 and then ghcjs-boot phase failed, maybe stack could check that?)

@fizruk

This comment has been minimized.

Show comment
Hide comment
@fizruk

fizruk Oct 12, 2015

Contributor

@k-bx you need to upgrade stack to HEAD, see Stack & GHCJS wiki

Contributor

fizruk commented Oct 12, 2015

@k-bx you need to upgrade stack to HEAD, see Stack & GHCJS wiki

@k-bx

This comment has been minimized.

Show comment
Hide comment
@k-bx

k-bx Oct 12, 2015

Contributor

Sorry, my bad, mis-read wiki.

Contributor

k-bx commented Oct 12, 2015

Sorry, my bad, mis-read wiki.

@tinkyholloway

This comment has been minimized.

Show comment
Hide comment
@tinkyholloway

tinkyholloway Oct 15, 2015

I've been working to the instructions at Stack & GHCJS.

I've found a problem with hsc2hs (whatever that is) when fails on a build of network-2.6.2.1:

hsc2hs-ghcjs-0.2.0.20151001-7.10.2.bin: hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

hsc2hs is present:

✔ ~/.stack/programs/x86_64-osx/ghcjs-0.2.0.20151001_ghc-7.10.2/bin
13:07 $ ~/.stack/programs/x86_64-osx/ghcjs-0.2.0.20151001_ghc-7.10.2/bin/hsc2hs-ghcjs
hsc2hs-ghcjs-0.2.0.20151001-7.10.2.bin: hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

tinkyholloway commented Oct 15, 2015

I've been working to the instructions at Stack & GHCJS.

I've found a problem with hsc2hs (whatever that is) when fails on a build of network-2.6.2.1:

hsc2hs-ghcjs-0.2.0.20151001-7.10.2.bin: hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

hsc2hs is present:

✔ ~/.stack/programs/x86_64-osx/ghcjs-0.2.0.20151001_ghc-7.10.2/bin
13:07 $ ~/.stack/programs/x86_64-osx/ghcjs-0.2.0.20151001_ghc-7.10.2/bin/hsc2hs-ghcjs
hsc2hs-ghcjs-0.2.0.20151001-7.10.2.bin: hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)
@luite

This comment has been minimized.

Show comment
Hide comment
@luite

luite Oct 15, 2015

Ok this is likely a problem with how hsc2hs is dealt with in GHCJS. It's the only tool that isn't stand-alone, but a wrapper that calls an existing hsc2hs provided by GHC.

Handling of these files is not quite complete yet, but something should probably change. I wonder if GHCJS should even attempt to support them, since it's really for getting information from the C compiler.

luite commented Oct 15, 2015

Ok this is likely a problem with how hsc2hs is dealt with in GHCJS. It's the only tool that isn't stand-alone, but a wrapper that calls an existing hsc2hs provided by GHC.

Handling of these files is not quite complete yet, but something should probably change. I wonder if GHCJS should even attempt to support them, since it's really for getting information from the C compiler.

@tinkyholloway

This comment has been minimized.

Show comment
Hide comment
@tinkyholloway

tinkyholloway Oct 15, 2015

@luite said:

It's ... a wrapper that calls an existing hsc2hs provided by GHC

A ha! Adding ~/.stack/programs/x86_64-osx/ghc-7.10.2/bin/hsc2hs to my path fixed it. Thank you.

tinkyholloway commented Oct 15, 2015

@luite said:

It's ... a wrapper that calls an existing hsc2hs provided by GHC

A ha! Adding ~/.stack/programs/x86_64-osx/ghc-7.10.2/bin/hsc2hs to my path fixed it. Thank you.

@eallik

This comment has been minimized.

Show comment
Hide comment
@eallik

eallik Oct 29, 2015

Contributor

will we be seeing any GHCJS related doc on https://www.stackage.org at some point?

Contributor

eallik commented Oct 29, 2015

will we be seeing any GHCJS related doc on https://www.stackage.org at some point?

@bitemyapp

This comment has been minimized.

Show comment
Hide comment
@bitemyapp

bitemyapp Oct 29, 2015

Contributor

@eallik @snoyberg related to Stackage, being able to list available snapshots (LTS, nightly) would be nice. If that is possible, it was impossible to find via the website.

Would a separate set of Stackage snapshots for what's "known good" w/ GHCJS be sensible?

Contributor

bitemyapp commented Oct 29, 2015

@eallik @snoyberg related to Stackage, being able to list available snapshots (LTS, nightly) would be nice. If that is possible, it was impossible to find via the website.

Would a separate set of Stackage snapshots for what's "known good" w/ GHCJS be sensible?

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 29, 2015

Collaborator

@eallik Possibly! I don't think there's much to stackage itself related to GHCJS, though, so I imagine that this will be documented in stack / in tutorials elsewhere.

@bitemyapp If you want to read the nitty-gritty of the decision making process on that, here's the issue related to adding support for using GHCJS with stackage snapshots: #1190 . So, essentially there is no need for a separate set of stackage snapshots, and ghcjs-only packages will probably get added to stackage.

Collaborator

mgsloan commented Oct 29, 2015

@eallik Possibly! I don't think there's much to stackage itself related to GHCJS, though, so I imagine that this will be documented in stack / in tutorials elsewhere.

@bitemyapp If you want to read the nitty-gritty of the decision making process on that, here's the issue related to adding support for using GHCJS with stackage snapshots: #1190 . So, essentially there is no need for a separate set of stackage snapshots, and ghcjs-only packages will probably get added to stackage.

@bitemyapp

This comment has been minimized.

Show comment
Hide comment
@bitemyapp

bitemyapp Oct 29, 2015

Contributor

@mgsloan I had assumed there wouldn't be a separate compiler field, but rather that snapshots and compilers would be bolted together with a separate submission process for GHCJS.

Much as GHCJS has done a great job with compatibility, I'm not sure it makes sense to elide the distinction in the snapshots when that distinction is made for major GHC versions.

Contributor

bitemyapp commented Oct 29, 2015

@mgsloan I had assumed there wouldn't be a separate compiler field, but rather that snapshots and compilers would be bolted together with a separate submission process for GHCJS.

Much as GHCJS has done a great job with compatibility, I'm not sure it makes sense to elide the distinction in the snapshots when that distinction is made for major GHC versions.

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 29, 2015

Collaborator

Yes, once there's a version of GHCJS on hackage, it would be good to get it and its associated libraries into stackage. I suppose when that happens, it'll be desireable to have just plain ghcjs be a valid value for compiler, where the ghc and ghcjs version is provided by the snapshot.

Until then, manually specifying the compiler is the best way I can think of for this to work.

Collaborator

mgsloan commented Oct 29, 2015

Yes, once there's a version of GHCJS on hackage, it would be good to get it and its associated libraries into stackage. I suppose when that happens, it'll be desireable to have just plain ghcjs be a valid value for compiler, where the ghc and ghcjs version is provided by the snapshot.

Until then, manually specifying the compiler is the best way I can think of for this to work.

@eallik

This comment has been minimized.

Show comment
Hide comment
@eallik

eallik Oct 29, 2015

Contributor

@mgsloan how about your own comment here 3 months ago? there seems to be quite a bit of information in this thread that solely applies to using stack with GHCJS? shouldn't that constitute the GHCJS specific portion of the doc?

Contributor

eallik commented Oct 29, 2015

@mgsloan how about your own comment here 3 months ago? there seems to be quite a bit of information in this thread that solely applies to using stack with GHCJS? shouldn't that constitute the GHCJS specific portion of the doc?

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 29, 2015

Collaborator

@eallik I didn't properly understand how GHCJS worked 3 months ago. Another relevant issue is here: fpco/stackage-curator#8 . Which doc do you think this stuff should be added to?

Collaborator

mgsloan commented Oct 29, 2015

@eallik I didn't properly understand how GHCJS worked 3 months ago. Another relevant issue is here: fpco/stackage-curator#8 . Which doc do you think this stuff should be added to?

@eallik

This comment has been minimized.

Show comment
Hide comment
@eallik

eallik Oct 29, 2015

Contributor

I'm not sure; so one can just use stack/stackage with GHCJS without having to know about how stack works with GHCJS?

Contributor

eallik commented Oct 29, 2015

I'm not sure; so one can just use stack/stackage with GHCJS without having to know about how stack works with GHCJS?

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 30, 2015

Collaborator

@eallik It should be pretty straightforward, but the docs certainly deserved more polish. I've done that in the following commits:

Another benefit of using the same stackage snapshots for GHCJS is that you can take existing stack projects intended for GHC and build them with GHCJS via stack build --compiler ghcjs-0.1.0.20150924_ghc-7.10.2. Once ghcjs is in stackage snapshots, it will be possible to just do stack build --compiler ghcjs or perhaps even stack build --ghcjs

Collaborator

mgsloan commented Oct 30, 2015

@eallik It should be pretty straightforward, but the docs certainly deserved more polish. I've done that in the following commits:

Another benefit of using the same stackage snapshots for GHCJS is that you can take existing stack projects intended for GHC and build them with GHCJS via stack build --compiler ghcjs-0.1.0.20150924_ghc-7.10.2. Once ghcjs is in stackage snapshots, it will be possible to just do stack build --compiler ghcjs or perhaps even stack build --ghcjs

@eallik

This comment has been minimized.

Show comment
Hide comment
@eallik

eallik Oct 30, 2015

Contributor

Thank you! Exactly what I meant :)

Contributor

eallik commented Oct 30, 2015

Thank you! Exactly what I meant :)

@nrolland

This comment has been minimized.

Show comment
Hide comment
@nrolland

nrolland Oct 31, 2015

Contributor

I updated @fizruk's build as of 2015-10-29

resolver: ghcjs-0.2.0.20151029_ghc-7.10.2
compiler-check: match-exact
setup-info:
  ghcjs:
      source:
            ghcjs-0.2.0.20151029_ghc-7.10.2:
                    url: "https://github.com/nrolland/ghcjs/releases/download/v0.2.0.20151029/ghcjs-0.2.0.20151029.tar.gz"

also had success setuping + building with

resolver: lts-3.0
packages:
- '.'
compiler-check: match-exact
setup-info:
  ghcjs:
      source:
            ghcjs-0.2.0.20151029_ghc-7.10.2:
                    url: "https://github.com/nrolland/ghcjs/releases/download/v0.2.0.20151029/ghcjs-0.2.0.20151029.tar.gz"

and stack setup --compiler ghcjs-0.2.0.20151029_ghc-7.10.2 stack build --compiler ghcjs-0.2.0.20151029_ghc-7.10.2

Contributor

nrolland commented Oct 31, 2015

I updated @fizruk's build as of 2015-10-29

resolver: ghcjs-0.2.0.20151029_ghc-7.10.2
compiler-check: match-exact
setup-info:
  ghcjs:
      source:
            ghcjs-0.2.0.20151029_ghc-7.10.2:
                    url: "https://github.com/nrolland/ghcjs/releases/download/v0.2.0.20151029/ghcjs-0.2.0.20151029.tar.gz"

also had success setuping + building with

resolver: lts-3.0
packages:
- '.'
compiler-check: match-exact
setup-info:
  ghcjs:
      source:
            ghcjs-0.2.0.20151029_ghc-7.10.2:
                    url: "https://github.com/nrolland/ghcjs/releases/download/v0.2.0.20151029/ghcjs-0.2.0.20151029.tar.gz"

and stack setup --compiler ghcjs-0.2.0.20151029_ghc-7.10.2 stack build --compiler ghcjs-0.2.0.20151029_ghc-7.10.2

@emmanueltouzery

This comment has been minimized.

Show comment
Hide comment
@emmanueltouzery

emmanueltouzery Jan 25, 2016

I'm not really sure if this is the right place to ask, but... I have a working setup, there's just one little hitch: stack install works, until the copying bit: then it says Couldn't find executable cigale-web in directory [..]. Indeed in that directory, there is no cigale-web executable, but instead there is a cigale-web.exe subfolder (that ideally stack could copy recursively to my local-bin-path).

I'll probably handle this in a custom Setup.hs, but maybe there is a nicer solution that I'm missing here? Or is this still TODO?

emmanueltouzery commented Jan 25, 2016

I'm not really sure if this is the right place to ask, but... I have a working setup, there's just one little hitch: stack install works, until the copying bit: then it says Couldn't find executable cigale-web in directory [..]. Indeed in that directory, there is no cigale-web executable, but instead there is a cigale-web.exe subfolder (that ideally stack could copy recursively to my local-bin-path).

I'll probably handle this in a custom Setup.hs, but maybe there is a nicer solution that I'm missing here? Or is this still TODO?

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Jan 25, 2016

Collaborator

@emmanueltouzery Yeah, you should just use stack build for ghcjs. stack install is just an alias for stack build --copy, adding on the extra copy step. Feel free to open an issue about that. While this should work in theory, it's actually kinda nice, I'd rather not have node versions of haskell exes laying around on my PATH.

Collaborator

mgsloan commented Jan 25, 2016

@emmanueltouzery Yeah, you should just use stack build for ghcjs. stack install is just an alias for stack build --copy, adding on the extra copy step. Feel free to open an issue about that. While this should work in theory, it's actually kinda nice, I'd rather not have node versions of haskell exes laying around on my PATH.

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg Jan 26, 2016

Contributor

I've actually had use cases where copying the JavaScript files elsewhere
would have been convenient

On Mon, Jan 25, 2016, 10:41 PM Michael Sloan notifications@github.com
wrote:

@emmanueltouzery https://github.com/emmanueltouzery Yeah, you should
just use stack build for ghcjs. stack install is just an alias for stack
build --copy, adding on the extra copy step. Feel free to open an issue
about that. While this should work in theory, it's actually kinda nice, I'd
rather not have node versions of haskell exes laying around on my PATH.


Reply to this email directly or view it on GitHub
#337 (comment)
.

Contributor

snoyberg commented Jan 26, 2016

I've actually had use cases where copying the JavaScript files elsewhere
would have been convenient

On Mon, Jan 25, 2016, 10:41 PM Michael Sloan notifications@github.com
wrote:

@emmanueltouzery https://github.com/emmanueltouzery Yeah, you should
just use stack build for ghcjs. stack install is just an alias for stack
build --copy, adding on the extra copy step. Feel free to open an issue
about that. While this should work in theory, it's actually kinda nice, I'd
rather not have node versions of haskell exes laying around on my PATH.


Reply to this email directly or view it on GitHub
#337 (comment)
.

@agocorona

This comment has been minimized.

Show comment
Hide comment
@agocorona

agocorona Oct 18, 2016

So finally there is first class install for ghcjs?.

I would like to install it in remote servers with scarce resources. For example in free instances of Cloud9 to enable users to clone and run example code. I can not do an installation from source there.

As a workaround, anyone know how to package and install the binaries manually? cloud9 workspaces are docker instances, so I can compile it in docker locally and translate the binaries.

agocorona commented Oct 18, 2016

So finally there is first class install for ghcjs?.

I would like to install it in remote servers with scarce resources. For example in free instances of Cloud9 to enable users to clone and run example code. I can not do an installation from source there.

As a workaround, anyone know how to package and install the binaries manually? cloud9 workspaces are docker instances, so I can compile it in docker locally and translate the binaries.

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 18, 2016

Collaborator

So finally there is first class install for ghcjs?.

Stack has supported setting up GHCJS since v0.1.8, back in November of 2015

I would like to install it in remote servers with scarce resources. For example in free instances of Cloud9 to enable users to clone and run example code. I can not do an installation from source there.

Perhaps use docker? You may need to figure out how to do a binary distribution of GHCJS, afaik no one has figured out how to do a binary distribution, other than mechanisms like docker.

Collaborator

mgsloan commented Oct 18, 2016

So finally there is first class install for ghcjs?.

Stack has supported setting up GHCJS since v0.1.8, back in November of 2015

I would like to install it in remote servers with scarce resources. For example in free instances of Cloud9 to enable users to clone and run example code. I can not do an installation from source there.

Perhaps use docker? You may need to figure out how to do a binary distribution of GHCJS, afaik no one has figured out how to do a binary distribution, other than mechanisms like docker.

@ryantrinkle

This comment has been minimized.

Show comment
Hide comment
@ryantrinkle

ryantrinkle Oct 18, 2016

@mgsloan Maybe we can get stack to use nix's binary package distribution infrastructure somehow?

ryantrinkle commented Oct 18, 2016

@mgsloan Maybe we can get stack to use nix's binary package distribution infrastructure somehow?

@mgsloan

This comment has been minimized.

Show comment
Hide comment
@mgsloan

mgsloan Oct 19, 2016

Collaborator

@ryantrinkle Perhaps so! Yes, nix is also a great approach, as demonstrated by your repo https://github.com/reflex-frp/reflex-platform

Collaborator

mgsloan commented Oct 19, 2016

@ryantrinkle Perhaps so! Yes, nix is also a great approach, as demonstrated by your repo https://github.com/reflex-frp/reflex-platform

@geraldus

This comment has been minimized.

Show comment
Hide comment
@geraldus

geraldus Nov 7, 2016

Looks like runInteractiveProcess issue is still appears (I got it on my Travis GHCJS build via stack using LTS 7.7 with according compiler snapshot from Marcin).

Sample error message:

hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

To resolve this I added stack --no-terminal --install-ghc install hsc2hs in build section for GHCJS case (see this commit).

geraldus commented Nov 7, 2016

Looks like runInteractiveProcess issue is still appears (I got it on my Travis GHCJS build via stack using LTS 7.7 with according compiler snapshot from Marcin).

Sample error message:

hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

To resolve this I added stack --no-terminal --install-ghc install hsc2hs in build section for GHCJS case (see this commit).

@haskellstudio

This comment has been minimized.

Show comment
Hide comment
@haskellstudio

haskellstudio Apr 8, 2018

hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

i resolve this by :

vim ~/.bash_profile 
export PATH=$PATH:/Users/yourMacUserName/.stack/programs/x86_64-osx/ghc-8.0.1/bin:/Users/hack/.local/bin

because hsc2hs is in /Users/yourMacUserName/.stack/programs/x86_64-osx/ghc-8.0.1/bin

haskellstudio commented Apr 8, 2018

hsc2hs: rawSystem: runInteractiveProcess: exec: does not exist (No such file or directory)

i resolve this by :

vim ~/.bash_profile 
export PATH=$PATH:/Users/yourMacUserName/.stack/programs/x86_64-osx/ghc-8.0.1/bin:/Users/hack/.local/bin

because hsc2hs is in /Users/yourMacUserName/.stack/programs/x86_64-osx/ghc-8.0.1/bin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment