cincheo / jsweet

A Java to JavaScript transpiler.
http://www.jsweet.org
Other
1.45k stars 159 forks source link

Fails finding node from Eclipse in OSX #722

Open priandsf opened 2 years ago

priandsf commented 2 years ago

Hello - there are many ways to install Node, and my machine is using Volta, thus Node appears here:

priand@priand-mac java % which node
/Users/priand/.volta/bin/node

This breaks when being called from Eclipse as I saw there is already a hack for Eclipse in OSX. A great solution would be to add optional node/npm paths to the configuration. This way we can install Node using a maven dependency (see: https://github.com/eirslett/frontend-maven-plugin) and reference these paths in the JSweet configuration. Not only it removes the prerequisites to run a project, but it also allows a fine grained control of the Node version being used.

kohlschuetter commented 9 months ago

For the time being, you can create a symbolic link from /usr/local/bin/node to your node installation, then it should work. Also add a symbolic link from /usr/local/bin/npm to your npm binary.