iliakan / iliakan/javascript-precommit
Not able to install it on Windows
未關閉
還沒有人認領這個 Issue。
- 主要語言
- JavaScript
- 星號
- 6
- 分支
- 1
- PR 合併指標
- 30 天內沒有已合併 PR
描述
When I tried to npm install javasciprt-precommit, it gave me an error:
> javascript-precommit@0.0.8 postinstall C:\gitlib\javascript-precommit
> ./bin/postinstall.js
'.' 不是内部或外部命令,也不是可运行的程序
或批处理文件。
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! node v0.12.0
npm ERR! npm v2.5.1
npm ERR! code ELIFECYCLE
npm ERR! javascript-precommit@0.0.8 postinstall: `./bin/postinstall.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the javascript-precommit@0.0.8 postinstall script './bin/postinstall.js'.
npm ERR! This is most likely a problem with the javascript-precommit package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! ./bin/postinstall.js
npm ERR! You can get their info via:
npm ERR! npm owner ls javascript-precommit
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\gitlib\javascript-precommit\npm-debug.log
The chinese character in the error log above means '.' is not a valid command.
I could fix this by modify the package.json from
"scripts": {
"postinstall": "./bin/postinstall.js",
"uninstall": "./bin/uninstall.js"
},
to
"scripts": {
"postinstall": "node ./bin/postinstall.js",
"uninstall": "node ./bin/uninstall.js"
},
Could you please help fix this? Thanks for your great work 😄
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
首先檢查 package.json 以及其中引用的 bin/postinstall.js 和 bin/uninstall.js 指令碼。驗證 npm install 和 npm uninstall 是否能在 Windows 上成功呼叫這些指令碼,並確認現有的 precommit hook 行為維持不變。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- javascript, node.js
- 領域
- tooling
- Issue 類型
- 缺陷
- 難度
- 1/5
- 預估耗時
- 1 小時以內
- 活躍度
- 停滯
- 描述清晰度
- 描述清楚
- 新手友好度
- 55/100