-
Notifications
You must be signed in to change notification settings - Fork 61
Description
process.env.PWD is domain specific and might not return the correct value everywhere and is also assuming that the main/index.js of an application would be present at the same level as the node_modules folder.
var PATH_TO_JAVA_BRIDGE1 = process.env.PWD + "/node_modules/sybase/JavaSybaseLink/dist/JavaSybaseLink.jar";
When I was trying to run it on windows, the process.env.PWD was returned as undefined.
As you have already put a comment in the src code over that line,
//FIXME: this is bad should be a way to expose this jar file in the npm package
//so that it can be called properly from parent packages.
I would suggest using the following syntax:
var path = require("path");
var PATH_TO_JAVA_BRIDGE1 = path.join(__dirname, "..", "/JavaSybaseLink/dist/JavaSybaseLink.jar");