mathisonian / mathisonian/command-exists
False positive if there is a folder with the same name as the command in question
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 147
- Forks
- 22
- PR merge metrics
- No merged PRs in 30d
Description
Hi there...
I'm trying your module.. But it throws false positives when testing for a command with the same name as a folder at the testing location...
For example..
```bash
/myProject
/myFolderName
/anotherFolder
/myCommand <-- folder with the same name as the command.
```
If I test `commandExists('myCommand')` inside `myProject` it will throw `true` because of the folder with the same name as the command.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the commandExists implementation and reproduce the reported layout with a folder named myCommand. Verify that a directory with the command name is not treated as an existing command, while preserving the expected command lookup behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100