mirror of
https://github.com/denoland/deno.git
synced 2025-08-04 19:08:15 +00:00
fix(npm): binary entrypoint for .js or no extension (#15900)
This commit is contained in:
parent
6a9acc8142
commit
7b98282993
9 changed files with 47 additions and 10 deletions
5
cli/tests/testdata/npm/registry/@denotest/bin/1.0.0/cli-cjs.js
vendored
Normal file
5
cli/tests/testdata/npm/registry/@denotest/bin/1.0.0/cli-cjs.js
vendored
Normal file
|
@ -0,0 +1,5 @@
|
|||
const process = require("process");
|
||||
|
||||
for (const arg of process.argv.slice(2)) {
|
||||
console.log(arg);
|
||||
}
|
5
cli/tests/testdata/npm/registry/@denotest/bin/1.0.0/cli-no-ext
vendored
Normal file
5
cli/tests/testdata/npm/registry/@denotest/bin/1.0.0/cli-no-ext
vendored
Normal file
|
@ -0,0 +1,5 @@
|
|||
const process = require("process");
|
||||
|
||||
for (const arg of process.argv.slice(2)) {
|
||||
console.log(arg);
|
||||
}
|
9
cli/tests/testdata/npm/registry/@denotest/bin/1.0.0/package.json
vendored
Normal file
9
cli/tests/testdata/npm/registry/@denotest/bin/1.0.0/package.json
vendored
Normal file
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"name": "@deno/bin",
|
||||
"version": "1.0.0",
|
||||
"bin": {
|
||||
"cli-esm": "./cli.mjs",
|
||||
"cli-no-ext": "./cli-no-ext",
|
||||
"cli-cjs": "./cli-cjs.js"
|
||||
}
|
||||
}
|
|
@ -1,5 +0,0 @@
|
|||
{
|
||||
"name": "@deno/esm-bin",
|
||||
"version": "1.0.0",
|
||||
"bin": "./cli.mjs"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue