Open xxi-arch opened 6 years ago
应该不是我的问题
0 info it worked if it ends with ok
1 verbose cli [ 'C:\Program Files\nodejs\node.exe',
1 verbose cli 'C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'build' ]
2 info using npm@5.6.0
3 info using node@v8.9.4
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle iview-admin-template@1.0.0~prebuild: iview-admin-template@1.0.0
6 info lifecycle iview-admin-template@1.0.0~build: iview-admin-template@1.0.0
7 verbose lifecycle iview-admin-template@1.0.0~build: unsafe-perm in lifecycle true
8 verbose lifecycle iview-admin-template@1.0.0~build: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\root\phpStudy_2016.11.03\WWW\public\node_modules.bin;C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Program Files (x86)\WinSCP\;C:\Program Files (x86)\Java\jdk1.8.0_144\bin;C:\Program Files\nodejs\;C:\Users\乐而\AppData\Local\Programs\Python\Python36-32\Scripts\;C:\Users\乐而\AppData\Local\Programs\Python\Python36-32\;C:\Program Files (x86)\Python\Python36-32\Scripts;C:\Program Files (x86)\Python\Python36-32;C:\Users\乐而\AppData\Local\Microsoft\WindowsApps;C:\Users\乐而\AppData\Roaming\npm
9 verbose lifecycle iview-admin-template@1.0.0~build: CWD: C:\root\phpStudy_2016.11.03\WWW\public
10 silly lifecycle iview-admin-template@1.0.0~build: Args: [ '/d /s /c',
10 silly lifecycle 'webpack --progress --hide-modules --config build/webpack.prod.config.js' ]
11 silly lifecycle iview-admin-template@1.0.0~build: Returned: code: 2 signal: null
12 info lifecycle iview-admin-template@1.0.0~build: Failed to exec build script
13 verbose stack Error: iview-admin-template@1.0.0 build: webpack --progress --hide-modules --config build/webpack.prod.config.js
13 verbose stack Exit status 2
13 verbose stack at EventEmitter.webpack --progress --hide-modules --config build/webpack.prod.config.js
22 error Exit status 2
23 error Failed at the iview-admin-template@1.0.0 build script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 2, true ]
我用的是简化版
{ test: /iview.src.*?js$/, loader: 'babel-loader' }
@544751779 项目根目录新建一个.babelrc的文件写入
{ "presets": ["es2015"] }