运行 NPM run watch-poll 报错
运行 npm run watch-poll 报错
webpack.js
const mix = require(‘laravel-mix’);
/*
|————————————————————————– | Mix Asset Management |————————————————————————– | | Mix provides a clean, fluent API for defining some Webpack build steps | for your Laravel application. By default, we are compiling the Sass | file for the application as well as bundling up all the JS files. | */
mix.js(‘resources/js/app.js’, ‘public/js’)
.sass(‘resources/sass/app.scss’, ‘public/css’)
.version()
.copyDirectory(‘resources/editor/js’, ‘public/js’)
.copyDirectory(‘resources/editor/css’, ‘public/css’);
日志文件
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli ‘/www/server/nvm/versions/node/v12.16.1/bin/node’,
1 verbose cli ‘/www/server/nvm/versions/node/v12.16.1/bin/npm’,
1 verbose cli ‘run’,
1 verbose cli ‘watch-poll’
1 verbose cli ]
2 info using npm@6.13.4
3 info using node@v12.16.1
4 verbose run-script [ ‘prewatch-poll’, ‘watch-poll’, ‘postwatch-poll’ ]
5 info lifecycle @prewatch-poll: @watch-poll: @
6 info lifecycle @
7 verbose lifecycle @watch-poll: unsafe-perm in lifecycle truewatch-poll: PATH: /www/server/nvm/versions/node/v12.16.1/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/www/wwwroot/www.*.com/blog/node_modules/.bin:/www/server/nvm/versions/node/v12.16.1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin
8 verbose lifecycle @
9 verbose lifecycle @~watch-poll: CWD: /www/wwwroot/www..com/blog
10 silly lifecycle @watch-poll: Args: [ ‘-c’, ‘npm run watch – –watch-poll’ ]watch-poll: Returned: code: 1 signal: null
11 silly lifecycle @
12 info lifecycle @~watch-poll: Failed to exec watch-poll script
13 verbose stack Error: @ watch-poll: npm run watch -- --watch-poll
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (/www/server/nvm/versions/node/v12.16.1/lib/node_modules/npm/node_modules/npm-lifecycle/index.js16)
13 verbose stack at EventEmitter.emit (events.js20)
13 verbose stack at ChildProcess. (/www/server/nvm/versions/node/v12.16.1/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js14)
13 verbose stack at ChildProcess.emit (events.js20)
13 verbose stack at maybeClose (internal/child_process.js16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js5)
14 verbose pkgid @
15 verbose cwd /www/wwwroot/www.*****.com/blog
16 verbose Linux 3.10.0-693.2.2.el7.x86_64
17 verbose argv “/www/server/nvm/versions/node/v12.16.1/bin/node” “/www/server/nvm/versions/node/v12.16.1/bin/npm” “run” “watch-poll”
18 verbose node v12.16.1
19 verbose npm v6.13.4
20 error code ELIFECYCLE
21 error errno 1
22 error @ watch-poll: npm run watch -- --watch-poll
22 error Exit status 1
23 error Failed at the @ watch-poll script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
求大神指点
推荐文章: