Giter Club home page Giter Club logo

Comments (2)

HeinrichApfelmus avatar HeinrichApfelmus commented on September 26, 2024

I had a similar problem. It seems to me that stack needs to have the path to its own binary in the PATH variable. I could fix my own issue by changing

https://github.com/HeinrichApfelmus/hyper-haskell/blob/master/app/src/interpreter.js#L52

to read

env['PATH']  = process.env['PATH'] + ':/usr/local/bin' // pick up path from external environment if possible

My reasoning was that this path is standard enough and it doesn't hurt to include it.

In your case, this trick doesn't work, because your stack binary is not in a standard location. A temporary fix would be simply add your nonstandard path by hand. You can mess around with the HyperHaskell.app bundle if you like, I think the JavaScript source code is included.

The proper fix would be to extract the path from the preferences

You make a good point that it's not clear when the preferences are applied.

from hyper-haskell.

2mol avatar 2mol commented on September 26, 2024

I have stack in ~/.local/bin/ too. I think it's pretty standard, so it wouldn't hurt to hardcode it in as well. Is it not possible to call which stack from within JS? Wouldn't process.env['PATH'] pick it up anyway, since the fact that stack is called means that it already is in the user's PATH?

Edit: stack is actually weird, in that it copies itself to both ~/.local/bin/ and /usr/local/bin/ in some (or all?) cases.

from hyper-haskell.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.