kentcdodds / kentcdodds/kcd-scripts
pre-commit script: doctoc.js could not be found
- Dominant language
- JavaScript
- Stars
- 889
- Forks
- 205
- PR merge metrics
- No merged PRs in 30d
Description
* `kcd-scripts` version: 0.37.0
because of the potential breaking change in 0.38, I decided not to upgrade
* `node` version: 0.8.4
* `npm` version: 0.5.3
* `windows` version: 10
### What you did:
While working on the PR for `cypress-testing-library`, I thought I'd enable the pre-commit hook. So I added the `.opt-in` file and added the `pre-commit` text to it. Then I did the git commit (both SourceTree and command line)
### What happened:
```
Running tasks for README.md [started]
Running tasks for README.md [failed]
→ .\node_modules\doctoc\doctoc.js could not be found. Try `npm install .\node_modules\doctoc\doctoc.js`.
```
`doctoc.js` does exist in the node_modules folder.
Contributor guide
Research direction
Reproduce the pre-commit run using the `.opt-in` file and `README.md`, then inspect how the hook resolves `node_modules/doctoc/doctoc.js`. Confirm the behavior with the reported kcd-scripts, Node, npm, and Windows versions; done means the pre-commit task completes without the missing-file error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- cli, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100