2014-12-11 94 views
1

我正在新筆記本電腦上設置Ember應用程序。我通過brew安裝了節點npm,並且我也安裝了Ember CLI。在灰燼CLI應用程序,我試圖做一個npm install但是當我做,我在終端得到這個錯誤:無法在Ember CLI應用程序中運行npm install?

npm WARN package.json [email protected] Non-dependency in bundleDependencies: inherits 
npm ERR! Darwin 14.0.0 
npm ERR! argv "node" "/usr/local/bin/npm" "install" 
npm ERR! node v0.10.33 
npm ERR! npm v2.1.11 
npm ERR! code E404 

npm ERR! 404 Not Found: expresss 
npm ERR! 404 
npm ERR! 404 'expresss' is not in the npm registry. 
npm ERR! 404 You should bug the author to publish it (or use the name yourself!) 
npm ERR! 404 It was specified as a dependency of 'ember-cli' 
npm ERR! 404 
npm ERR! 404 Note that you can also install from a 
npm ERR! 404 tarball, folder, http url, or git url. 

npm ERR! Please include the following file with any support request: 
npm ERR!  /Users/Nagarjun/Code/sumo-list/web-client/npm-debug.log 

我不能運行我的項目直到解決。我錯過了什麼?我什至谷歌搜索,但找不到任何表示

回答

0

查看您的package.json依賴項部分。看起來像一個錯字。

+0

我的package.json沒有爲「expresss」的任意字符串固定。這是我唯一具有「表達」的東西:「^ 4.1.1」,'。 – Nag 2014-12-11 05:04:36

+0

您是否也看過ember-cli package.json? – imahungry 2014-12-11 11:33:23

+0

我實際上對整個文件夾「expresss」做了一個確認,但沒有找到任何東西。 – Nag 2014-12-11 22:19:31

1

我的猜測是'expresss'(帶有一個額外的s)是npm上的一個包被拉的。這個依賴實際上是在ember-cli的package.json文件中列出的,但我認爲任何人都不會注意到它,直到後來的版本。

證明:https://github.com/stefanpenner/ember-cli/blob/ec8a6ab898599746bddbb8f72f7633c29f0ee95b/package.json#L58

+0

你是對的!但是,當我在系統中查找「expresss」這個詞時,它並沒有出現在任何地方。只有一次,它顯示在package.json文件中。見https://github.com/stefanpenner/ember-cli/issues/2723#issuecomment-66706275。我很困惑,我可以在我的新筆記本電腦上使用最新版本的node和npm來創建一個0.4 package.json。我能做些什麼來解決這個問題? – Nag 2014-12-12 22:03:17

1

我可以通過卸載節點,故宮完全利用BREW解決這個問題。然後,使用nodejs.org中的包安裝node.js。現在,我的npm版本是1.4.28。看起來問題是由更新的npm 2.1.10引起的。不知道爲什麼brew會自動選擇新的npm。

0

我面臨着同樣的問題,但它得到了通過運行sudo的NPM安裝-g燼-CLI