Windows 系统下设置Nodejs NPM全局路径

Windows下的Nodejs npm路径是appdata,很不爽,想改回来,可是在cmd下执行如下命令也无效node

npm config set cache "D:\nodejs\node_cache"npm

npm config set prefix "D:\nodejs\node_global"app

最后在nodejs的安装目录中找到node_modules\npm\.npmrc文件cmd

修改以下便可:ejs

prefix = D:\nodejs\node_global
cache = D:\nodejs\node_globalmodule

相关文章
相关标签/搜索