Date: Thu, 22 Jun 2023 22:44:54 +0200 From: Miroslav Lachman <000.fbsd@quip.cz> To: FreeBSD Ports <freebsd-ports@freebsd.org> Subject: Is it possible to build node package as single executable binary? Message-ID: <c50228d7-63c7-0e5c-7b38-d9e4c5a3e795@quip.cz>
next in thread | raw e-mail | index | archive | help
Node.js / npm packages can be built in to single executable binary containing all node modules and node.js executable = everything packaged in one large executable, but by default it works for Win, Mac and Linux, not for FreeBSD. Is there somebody successfully using it on FreeBSD? I would like to build Bitwarden's CLI command "bw" https://bitwarden.com/help/cli/ It can be installed on FreeBSD by "npm install @bitwarden/cli" and it works but can easily break with Node.js upgrade, that's why I would prefer to build it as single executable as it is distributed for Win, Max and Linux (it is called "Native executable" on Bitwearden's web) Source code is on Github https://github.com/bitwarden/clients/tree/master/apps/cli But I don't know how to build only apps/cli (npm install in this subdirectory failed with missing modules and npm install in top level failed on electron install, because it tries to build everything, not only CLI bw) Info for npm pkg https://github.com/vercel/pkg I am not node / JS developer, my knowledge of building node packages with npm / npx is very limited. Any help is really appreciated. Kind regards Miroslav Lachman
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?c50228d7-63c7-0e5c-7b38-d9e4c5a3e795>