NativeScript / NativeScript/nativescript-cli

`tns plugin add/remove` fails if there is dependency referenced as file

未關閉
#2,577 2 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

bug plugins severity: low
主要語言
JavaScript
星號
1.1k
分支
204
平均合併
1 天 9 小時
30 天內合併 PR
8

描述

Steps to reproduce:

git clone https://github.com/PeterStaev/NativeScript-Drop-Down
cd NativeScript-Drop-Down/demo
tns plugin remove tns-core-modules 

Result:

npm ERR! addLocal Could not install /Users/topuzov/Git/nativescript-cli-tests/NativeScript-Drop-Down/bin/dist
npm ERR! Darwin 16.1.0
npm ERR! argv "/usr/local/Cellar/node@6/6.9.5/bin/node" "/usr/local/bin/npm" "install"
npm ERR! node v6.9.5
npm ERR! npm  v3.10.10
npm ERR! path /Users/topuzov/Git/nativescript-cli-tests/NativeScript-Drop-Down/bin/dist
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall open

npm ERR! enoent ENOENT: no such file or directory, open '/Users/topuzov/Git/nativescript-cli-tests/NativeScript-Drop-Down/bin/dist'
npm ERR! enoent ENOENT: no such file or directory, open '/Users/topuzov/Git/nativescript-cli-tests/NativeScript-Drop-Down/bin/dist'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/topuzov/Git/nativescript-cli-tests/NativeScript-Drop-Down/demo/npm-debug.log

tns plugin add/remove fails if you have another dependency referenced with path:

"dependencies": {
  "nativescript-drop-down": "file:../bin/dist",
  "tns-core-modules": "^2.5.0"
},

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

使用相依性 "nativescript-drop-down": "file:../bin/dist" 和 tns plugin remove tns-core-modules 在 NativeScript-Drop-Down/demo 中重現該故障。先追蹤 tns plugin add/remove 如何處理以檔案為基礎的相依性。兩個命令都能在不出現 npm ENOENT 錯誤的情況下運作即表示完成。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
javascript
領域
cli
Issue 類型
缺陷
難度
3/5
預估耗時
1-2 天
活躍度
停滯
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。