无法卸载 angular-cli [英] Cannot uninstall angular-cli
问题描述
我已经多次尝试卸载我的 angular-cli 以更新它,但即使我按照 github 上提供的说明进行操作:
I've tried several times to uninstall my angular-cli in order to update it but even if I follow the instructions provided on github:
- npm uninstall -g @angular/cli
- npm 缓存清理
- npm install -g @angular/cli@latest
当我使用命令 ng --version 检查时,我仍然得到旧版本:
When I check using the command ng --version I still get the old version :
angular-cli: 1.0.0-beta.26
node: 7.7.1
os: darwin x64
我该如何解决这个问题?谢谢
How can i fix this issue? Thanks
推荐答案
如果您遇到 angular/cli 的问题,请使用以下命令:npm uninstall -g angular-cli
卸载 angular/cli.npm cache clean
从您的用户名下的应用数据文件夹中清除 npm 缓存.
使用 npm cache verify
来验证您的缓存是否已损坏.
使用 npm cache verify --force
从系统中清除整个缓存.
If you are facing issue with angular/cli then use the following commands:
npm uninstall -g angular-cli
to uninstall the angular/cli.
npm cache clean
to clean your npm cache from app data folder under your username.
use npm cache verify
to verify your cache whether it is corrupted or not.
use npm cache verify --force
to clean your entire cache from your system.
注意:
您也可以通过以下路径删除C:Users"Your_syste_User_name"AppDataRoaming
pm
和 C:Users"Your_syste_User_name"AppDataRoaming
pm-cache
然后使用以下命令在您的系统中全局安装最新的 angular/cli 版本.npm install -g @angular/cli@latest
要获取更多信息,请访问 github angular-cli 更新.
Note:
You can also delete by the following the paths
C:Users"Your_syste_User_name"AppDataRoaming
pm
and C:Users"Your_syste_User_name"AppDataRoaming
pm-cache
Then use the following command to install latest angular/cli version globally in your system.
npm install -g @angular/cli@latest
To get more information visit github angular-cli update.
这篇关于无法卸载 angular-cli的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!