which
Advanced tools
Comparing version 3.0.0 to 3.0.1
@@ -32,4 +32,9 @@ const isexe = require('isexe') | ||
if (isWindows) { | ||
const pathExtExe = optPathExt || ['.EXE', '.CMD', '.BAT', '.COM'].join(optDelimiter) | ||
const pathExt = pathExtExe.split(optDelimiter) | ||
const pathExtExe = optPathExt || | ||
['.EXE', '.CMD', '.BAT', '.COM'].join(optDelimiter) | ||
const pathExt = pathExtExe.split(optDelimiter).reduce((acc, item) => { | ||
acc.push(item) | ||
acc.push(item.toLowerCase()) | ||
return acc | ||
}, []) | ||
if (cmd.includes('.') && pathExt[0] !== '') { | ||
@@ -36,0 +41,0 @@ pathExt.unshift('') |
@@ -5,3 +5,3 @@ { | ||
"description": "Like which(1) unix command. Find the first instance of an executable in the PATH.", | ||
"version": "3.0.0", | ||
"version": "3.0.1", | ||
"repository": { | ||
@@ -21,3 +21,3 @@ "type": "git", | ||
"@npmcli/eslint-config": "^4.0.0", | ||
"@npmcli/template-oss": "4.8.0", | ||
"@npmcli/template-oss": "4.14.1", | ||
"tap": "^16.3.0" | ||
@@ -50,4 +50,5 @@ }, | ||
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", | ||
"version": "4.8.0" | ||
"version": "4.14.1", | ||
"publish": "true" | ||
} | ||
} |
@@ -34,8 +34,11 @@ # which | ||
Same as the BSD `which(1)` binary. | ||
Just like the BSD `which(1)` binary but using `node-which`. | ||
``` | ||
usage: which [-as] program ... | ||
usage: node-which [-as] program ... | ||
``` | ||
You can learn more about why the binary is `node-which` and not `which` | ||
[here](https://github.com/npm/node-which/pull/67) | ||
## OPTIONS | ||
@@ -42,0 +45,0 @@ |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
7472
139
52
1