Skip to content
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

Allow configuring esy path #452

Open
bbenne10 opened this issue May 29, 2020 · 0 comments
Open

Allow configuring esy path #452

bbenne10 opened this issue May 29, 2020 · 0 comments

Comments

@bbenne10
Copy link

Presently, src/analyze/BuildSystem.re (and maybe a few other places, I haven't checked too deeply) does not allow a configurable path to find esy and assumes that esy is in $PATH (or system equivalent) on launch.

This prevents a few different workflows:

  • esy installed globally, but with a unique npm prefix set to a directory that's not in a default $PATH (This is what I'm seeing. It's installed in ~/.local/bin, which I must push into $PATH by hand on OSX)
  • esy installed globally without overriding prefix: This just means that /usr/local isn't in $PATH
  • esy installed locally (and thus in <project_root>/node_modules/.bin): This is also pretty common and works amazingly with direnv (but unless that shell also starts rls, we're in trouble.

I am, admittedly, blissfully unaware of how hard this would be. It looks like BuildSystem.inferPackageManager and BuildSystem.detectFull are the only two places that Error("Couldn't get esy version") is thrown, but I have no idea where those functions are used (or if there're any other non-qualified uses of esy)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant