When I run pkg [file] --targets node13-win-x86 it gives me the error
> [email protected]
> Error! No available node version satisfies 'node13'
However, when I run node -v it outputs with v13.5.0.
I'm using Windows 10 build 1909.
same issue here
node -v
v13.6.0
Same here, but for Mac OS (node installed via homebrew):
> node -v
v13.8.0
> pkg -v
4.4.3
> sw_vers -productVersion
10.15.3
BTW can confirm that choosing node12-macos-x64 or latest-macos-x64 as targets does work.
Same issue for me.
â–“â–’â–‘ node -v
v13.8.0
â–“â–’â–‘ pkg -v
4.4.3
Same issue here.
> [email protected]
> Targets not specified. Assuming:
node13-linux-x64, node13-macos-x64, node13-win-x64
> Error! No available node version satisfies 'node13'
I'm using Node v13.7.0.
This is related to sub-project https://github.com/zeit/pkg-fetch which have to poses corresponding definitions and patches for specific nodejs versions.
Contributions are needed in pkg-fetch.
Another issue which confirms pkg architecture:
https://github.com/zeit/pkg/issues/331#issuecomment-447393268
Imho https://github.com/nexe/nexe is less complicated in its architecture and all needed things are in singular GitHub repository, but nexe also needs contributions in a similar matter - related to patching nodejs.
The problem of zeit/pkg-fetch is that it doesn't have any instructions on how we can contribute to it, helping to release new and updated versions.
I opened an issue here: https://github.com/zeit/pkg-fetch/issues/78
On my mac, use node8 will be help. While node9, node10...node13 doesn't work.
My node version is v13.6.0
$ pkg -t node8-macos index.js
> [email protected]
> Fetching base Node.js binaries to PKG_CACHE_PATH
fetched-v8.16.2-macos-x64 [====================] 100%
index index.js
Hope can help you.
use a node version manager like nvm, it looks like the latest version is 12.13.1
so nvm install 12.13.1 then run npm use 12.13.1 before running your builds
Bump ^ I am having troubles with ESM, which is fixed in latest 13.11.0
here's what i did (mac):
$ npm install -g n
$ n 13.0
$ pkg .
Maybe this can help: https://github.com/robertsLando/pkg-binaries
Most helpful comment
Maybe this can help: https://github.com/robertsLando/pkg-binaries