loading...

Discussion on: Bundle your Node app to a single executable for Windows, Linux and OsX

Collapse
frytaz1 profile image
frytaz1

Can i use pkg not to include node in my binary but just link it from separate file ?

Collapse
jochemstoel profile image
Jochem Stoel Author

I don't understand.

Collapse
frytaz1 profile image
frytaz1

Lets say i have few executables app1.exe, app2.exe, app3.exe and i want to save up disk space.
So i would like pkg not to bundle node executable inside each binary, but dynamically link it. Is this possible ?

Thread Thread
jochemstoel profile image
Jochem Stoel Author

Well I'm still not sure entirely what you mean but you could create a single bundle of Node with a set of dependencies that you need, then let it execute process.argv[2] or start a REPL if none is provided.

What you basically have then is an executable that behaves just like Node.exe but with a few extra modules already included.

Hope this helps you.