2016-11-25 28 views
-1

幫助!我是新來的科爾多瓦,節點,咕嚕,涼亭等ENOTFOUND包ng-cordova找不到

我想導入一個現有的科爾多瓦應用程序到Visual Studio 2015.當試圖更新依賴項(通過右鍵單擊項目資源管理器中的依賴項節點,並選擇「還原包」),我得到的輸出這樣的信息:

ENOTFOUND包NG-科爾多瓦沒有發現

我去一個命令提示符並運行:

npm install -g ng-cordova 

結果是:

npm WARN deprecated [email protected]: Please update conventional-changelog to >1.0.0. If you are running the cli, use conventional-changelog-cli 
[email protected] C:\Users\myuser\AppData\Roaming\npm\node_modules\ng-cordova 
├── [email protected] 
├── [email protected] 
├── [email protected] ([email protected], [email protected]) 
└── [email protected] ([email protected], [email protected], [email protected], [email protected]) 

有沒有工作?

我然後跑:

bower install 

不過得到的消息:

ENOTFOUND包NG-科爾多瓦沒有發現

以下是完整的輸出:

bower      invalid-meta bower      invalid-meta The "name" is recommended to be lowercase, can contain digits, dots, dashes 
bower font-awesome#~4.3.0 not-cached https://github.com/FortAwesome/Font-Awesome.git#~4.3.0 
bower font-awesome#~4.3.0  resolve https://github.com/FortAwesome/Font-Awesome.git#~4.3.0 
bower parse-js-sdk#~1.4.0  cached https://github.com/albemuth/parse-js-sdk.git#1.4.2 
bower parse-js-sdk#~1.4.0  validate 1.4.2 against https://github.com/albemuth/parse-js-sdk.git#~1.4.0 
bower angular#~1.2    cached https://github.com/angular/bower-angular.git#1.2.32 
bower angular#~1.2   validate 1.2.32 against https://github.com/angular/bower-angular.git#~1.2 
bower bootstrap#~3.2.0   cached https://github.com/twbs/bootstrap.git#3.2.0 
bower bootstrap#~3.2.0  validate 3.2.0 against https://github.com/twbs/bootstrap.git#~3.2.0 
bower angular-cookies#~1.2  cached https://github.com/angular/bower-angular-cookies.git#1.2.32 
bower angular-cookies#~1.2 validate 1.2.32 against https://github.com/angular/bower-angular-cookies.git#~1.2 
bower angular-resource#~1.2  cached https://github.com/angular/bower-angular-resource.git#1.2.32 
bower angular-resource#~1.2 validate 1.2.32 against https://github.com/angular/bower-angular-resource.git#~1.2 
bower angular-mocks#~1.2  cached https://github.com/angular/bower-angular-mocks.git#1.2.32 
bower angular-mocks#~1.2  validate 1.2.32 against https://github.com/angular/bower-angular-mocks.git#~1.2 
bower angular-animate#~1.2  cached https://github.com/angular/bower-angular-animate.git#1.2.32 
bower angular-animate#~1.2 validate 1.2.32 against https://github.com/angular/bower-angular-animate.git#~1.2 
bower angular-bootstrap#~0.10.0 cached https://github.com/angular-ui/bootstrap-bower.git#0.10.0 
bower angular-bootstrap#~0.10.0   validate 0.10.0 against https://github.com/angular-ui/bootstrap-bower.git#~0.10.0 
bower angular-sanitize#~1.2    cached https://github.com/angular/bower-angular-sanitize.git#1.2.32 
bower angular-sanitize#~1.2    validate 1.2.32 against https://github.com/angular/bower-angular-sanitize.git#~1.2 
bower angular-touch#~1.2     cached https://github.com/angular/bower-angular-touch.git#1.2.32 
bower angular-touch#~1.2    validate 1.2.32 against https://github.com/angular/bower-angular-touch.git#~1.2 
bower angular-ui-router#~0.2.10   cached https://github.com/angular-ui/angular-ui-router-bower.git#0.2.18 
bower angular-ui-router#~0.2.10   validate 0.2.18 against https://github.com/angular-ui/angular-ui-router-bower.git#~0.2.10 
bower moment#~2.10.2      cached https://github.com/moment/moment.git#2.10.6 
bower moment#~2.10.2     validate 2.10.6 against https://github.com/moment/moment.git#~2.10.2 
bower angular-ui-utils#~0.1.1    cached https://github.com/angular-ui/ui-utils.git#0.1.1 
bower angular-ui-utils#~0.1.1   validate 0.1.1 against https://github.com/angular-ui/ui-utils.git#~0.1.1 
bower font-awesome#~4.3.0    download https://github.com/FortAwesome/Font-Awesome/archive/v4.3.0.tar.gz 
bower font-awesome#~4.3.0    extract archive.tar.gz 
bower ng-cordova#~0.0.3    **ENOTFOUND Package ng-cordova not found** 

我再嘗試安裝ngcordova(不帶連字符):

bower install ngcordova 

輸出仍然有:

涼亭NG-科爾多瓦#〜0.0.3 ENOTFOUND包NG-科爾多瓦沒有發現

任何幫助將不勝感激。 謝謝!

+0

我再次--save安裝NG-科爾多瓦這樣的錯誤消息它更新了package.json。鮑爾仍然無法找到它,我不明白爲什麼: bower ng-cordova#^ 0.1.27-alpha ENOTFOUND包ng-cordova未找到 – BrianK

回答

1

第一條命令只回顯了有關另一個軟件包的警告(已廢棄的常規更改日誌@ 0.0.11),但ng-cordova已通過npm成功安裝。在你的第二個命令中,你拼錯了涼亭包的名字,因爲它是ngCordova,如圖所示on their github page上的自述。強烈建議閱讀自述文件。 (可能是爲什麼它被稱爲原因我讀)

如果一個軟件包無法通過NPM可以發現,你會得到像

$ npm i lkjsadflkjjlksdf 

npm ERR! Linux 4.4.0-42-generic 
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "i" "lkjsadflkjjlksdf" 
npm ERR! node v4.6.2 
npm ERR! npm v2.15.11 
npm ERR! code E404 

npm ERR! 404 Registry returned 404 for GET on https://registry.npmjs.org/lkjsadflkjjlksdf 
npm ERR! 404 
npm ERR! 404 'lkjsadflkjjlksdf' 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 
npm ERR! 404 Note that you can also install from a 
npm ERR! 404 tarball, folder, http url, or git url. 
+0

我編輯了bower.json並將包名更改爲「ngCordova」涼亭現在運行。謝謝您的幫助! – BrianK