NPM Notes

NPM global directory

C:\Users\xxx\AppData\Roaming\npm

Command Alias

If I have no access to modify system path, when I have some packages installed, I might use alias command. I have installed @angular/cli, in the way for using ng command.

$ alias ng='/c/Users/what_a_poor_user_with_no_access/AppData/Roaming/npm/ng'

List all global installed packages

$ npm list -g --depth=0

Windows Command Prompt

//get path environment
C:\Users\xxx>set path 

//append items to path. This is only available on CURRENT cmd window.
C:\Users\xxx>set path=%path%;C:\MyEnvironmentDirectory
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容