权限被拒绝的AngularCLI安装无法从远程存储库读取

问题描述 投票:0回答:1

我正在尝试在Ubuntu 14.04 LTS中安装Angular CLI,但出现此错误。我有各种解决方法,但我没有解决。其中一些是

  • 我试图将github添加到已知主机
  • 我为github创建了RSA密钥
  • 卸载并安装Node.js

我尽一切努力访问github都会响应此消息:权限被拒绝(公共密钥)

[sudo] password for efti: 
npm ERR! git clone [email protected]:angular/cli Cloning into bare repository '/home/efti/.npm/_git-remotes/git-github-com-angular-cli-515723dd'...
npm ERR! git clone [email protected]:angular/cli Permission denied (publickey).
npm ERR! git clone [email protected]:angular/cli fatal: Could not read from remote repository.
npm ERR! git clone [email protected]:angular/cli 
npm ERR! git clone [email protected]:angular/cli Please make sure you have the correct access rights
npm ERR! git clone [email protected]:angular/cli and the repository exists.
npm ERR! addLocal Could not install angular/cli
npm ERR! Error: ENOENT, stat 'angular/cli'
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>

npm ERR! System Linux 3.13.0-169-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "@angular/cli"
npm ERR! cwd /home/efti/.ssh
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path angular/cli
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /home/efti/.ssh/npm-debug.log
npm ERR! not ok code 0
angular permissions command-line-interface failed-installation
1个回答
0
投票

尝试使用https克隆:git clone https://github.com/angular/angular-cli.git

但是,如果要在系统上安装angular-cli global,则必须运行npm install -g @angular/cli

© www.soinside.com 2019 - 2024. All rights reserved.