PATH=C:\oraclexe\app\oracle\product\10.2.0\server\bin;C:\Windows\system32; C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\; c:\python32\python;C:\MinGW\bin;C:\Program Files\GTK2-Runtime\lib; C:\Program Files\MySQL\MySQL Server 5.5\bin;C:\Program Files\nodejs\; C:\Users\rg\AppData\Roaming\npm
node --version
C:\Users\Administrator>npm config ls ; cli configs metrics-registry = "https://registry.npm.taobao.org/" scope = "" user-agent = "npm/5.6.0 node/v10.2.0 win32 x64" ; userconfig C:\Users\Administrator\.npmrc cache = "D:\\npm\\node_cache" prefix = "D:\\npm\\global_node_modules" registry = "https://registry.npm.taobao.org/" ; builtin config undefined ; node bin location = D:\Program Files\nodejs\node.exe ; cwd = C:\Users\Administrator ; HOME = C:\Users\Administrator ; "npm config ls -l" to show all defaults.
metrics-registry = "https://registry.npm.taobao.org/"
這個是倉庫源cache = "D:\\npm\\node_cache""
這個是緩存prefix = "D:\\npm\\global_node_modules"
這個是儲存npm下載的包的本地倉庫地址更換本地倉庫地址:node
npm config set prefix 'D:\npm\global_node_modules' npm config set cache 'D:\npm\node_cache'
npm config set registry http://registry.npm.taobao.org/
npm info express
npm install webpack -g
webpack --version
查看webpack版本號