What Node versions, OSs and CPU architectures are you building for?
node20-macos-x64
Describe the Bug
Details
I'm using the pkg package to convert my NodeJS CLI application into a binary.
The Issue
Lately, I'm having issues with that.
When running my node binary application via MacOS terminal, without arguments - everything works just fine.
Once I add some commands to it, I get the following error:
Error: Cannot find module '*//'
The weird thing is that over other terminals, such as Warp, I do not get this error at all.
Examples
Warp - does not happen
MacOS Native Terminal - does happen
Without Arguments
With Arguments
Expected Behavior
Should not get this error across all terminals, no matter which one I'm using.
See that the error indicates that it trying to find a module which is the command itself.
To Reproduce
I think the easiest way to reproduce that would be through my CLI, which is open-source.
cd <YOUR_WORKING_DIR>
git clone https://github.com/Avivbens/shell-config.git
cd shell-config
npm i --legacy-peer-deps
npm run pack-local
cd executable
./shell-config install
What version of pkg are you using?
5.11.5
What version of Node.js are you using?
20
What operating system are you using?
macOS
What CPU architecture are you using?
Apple M1
What Node versions, OSs and CPU architectures are you building for?
node20-macos-x64
Describe the Bug
Details
I'm using the
pkg
package to convert my NodeJS CLI application into a binary.The Issue
Lately, I'm having issues with that. When running my node binary application via MacOS terminal, without arguments - everything works just fine. Once I add some commands to it, I get the following error: Error: Cannot find module '*//'
The weird thing is that over other terminals, such as Warp, I do not get this error at all.
Examples
Warp - does not happen
MacOS Native Terminal - does happen
Without Arguments
With Arguments
Expected Behavior
Should not get this error across all terminals, no matter which one I'm using.
See that the error indicates that it trying to find a module which is the command itself.
To Reproduce
I think the easiest way to reproduce that would be through my CLI, which is open-source.
Here is the link to the repo
To get it: