Skip to content
This repository has been archived by the owner on Sep 16, 2019. It is now read-only.

NPM run watch is not working! #367

Closed
danieldvos opened this issue Jun 17, 2015 · 6 comments
Closed

NPM run watch is not working! #367

danieldvos opened this issue Jun 17, 2015 · 6 comments

Comments

@danieldvos
Copy link

Here is the error-log output:

0 info it worked if it ends with ok
1 verbose cli [ 'C:\Program Files (x86)\nodejs\node.exe',
1 verbose cli 'C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'watch' ]
2 info using npm@2.5.1
3 info using node@v0.12.0
4 verbose node symlink C:\Program Files (x86)\nodejs\node.exe
5 verbose run-script [ 'prewatch', 'watch', 'postwatch' ]
6 info prewatch foundationpress@5.5.2
7 info watch foundationpress@5.5.2
8 verbose unsafe-perm in lifecycle true
9 info foundationpress@5.5.2 Failed to exec watch script
10 verbose stack Error: foundationpress@5.5.2 watch: grunt watch
10 verbose stack Exit status 3
10 verbose stack at EventEmitter. (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\lifecycle.js:213:16)
10 verbose stack at EventEmitter.emit (events.js:110:17)
10 verbose stack at ChildProcess. (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\spawn.js:14:12)
10 verbose stack at ChildProcess.emit (events.js:110:17)
10 verbose stack at maybeClose (child_process.js:1008:16)
10 verbose stack at Process.ChildProcess._handle.onexit (child_process.js:1080:5)
11 verbose pkgid foundationpress@5.5.2
12 verbose cwd C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
13 error Windows_NT 6.1.7601
14 error argv "C:\Program Files (x86)\nodejs\node.exe" "C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js" "run" "watch"
15 error node v0.12.0
16 error npm v2.5.1
17 error code ELIFECYCLE
18 error foundationpress@5.5.2 watch: grunt watch
18 error Exit status 3
19 error Failed at the foundationpress@5.5.2 watch script 'grunt watch'.
19 error This is most likely a problem with the foundationpress package,
19 error not with npm itself.
19 error Tell the author that this fails on your system:
19 error grunt watch
19 error You can get their info via:
19 error npm owner ls foundationpress
19 error There is likely additional logging output above.
20 verbose exit [ 1, true ]

@olefredrik
Copy link
Owner

Please verify that your package.json file is up to date. Then:

npm install

and finally

npm run watch

This should work. Keep me posted.

@danieldvos
Copy link
Author

Ole,

I verified that package.json is identical to the most recent version in Git, then tried npm install. It didn't work. Here is my error log:

0 info it worked if it ends with ok
1 verbose cli [ 'C:\Program Files (x86)\nodejs\node.exe',
1 verbose cli 'C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'install' ]
2 info using npm@2.5.1
3 info using node@v0.12.0
4 verbose node symlink C:\Program Files (x86)\nodejs\node.exe
5 verbose install where, deps [ 'C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme',
5 verbose install [ 'time-grunt',
5 verbose install 'bower',
5 verbose install 'grunt',
5 verbose install 'grunt-cli',
5 verbose install 'grunt-contrib-concat',
5 verbose install 'grunt-contrib-copy',
5 verbose install 'grunt-contrib-uglify',
5 verbose install 'grunt-contrib-watch',
5 verbose install 'grunt-sass',
5 verbose install 'grunt-string-replace',
5 verbose install 'node-sass' ] ]
6 verbose install where, peers [ 'C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme',
6 verbose install [] ]
7 info preinstall foundationpress@5.5.2
8 verbose already installed skipping time-grunt@^1.1.0 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
9 verbose already installed skipping bower@^1.4.1 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
10 verbose already installed skipping grunt@~0.4.1 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
11 verbose already installed skipping grunt-cli@^0.1.13 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
12 verbose already installed skipping grunt-contrib-concat@~0.3.0 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
13 verbose already installed skipping grunt-contrib-copy@~0.4.1 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
14 verbose already installed skipping grunt-contrib-uglify@~0.2.7 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
15 verbose already installed skipping grunt-contrib-watch@~0.5.3 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
16 verbose already installed skipping grunt-sass@~0.18.0 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
17 verbose already installed skipping grunt-string-replace@~0.2.7 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
18 verbose already installed skipping node-sass@~2.0.1 C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
19 silly install resolved []
20 info build C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
21 verbose linkStuff [ false,
21 verbose linkStuff false,
21 verbose linkStuff false,
21 verbose linkStuff 'C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes' ]
22 info linkStuff foundationpress@5.5.2
23 verbose linkBins foundationpress@5.5.2
24 verbose linkMans foundationpress@5.5.2
25 verbose rebuildBundles foundationpress@5.5.2
26 verbose rebuildBundles [ '.bin',
26 verbose rebuildBundles 'bower',
26 verbose rebuildBundles 'grunt',
26 verbose rebuildBundles 'grunt-cli',
26 verbose rebuildBundles 'grunt-contrib-concat',
26 verbose rebuildBundles 'grunt-contrib-copy',
26 verbose rebuildBundles 'grunt-contrib-uglify',
26 verbose rebuildBundles 'grunt-contrib-watch',
26 verbose rebuildBundles 'grunt-sass',
26 verbose rebuildBundles 'grunt-string-replace',
26 verbose rebuildBundles 'node-sass',
26 verbose rebuildBundles 'time-grunt' ]
27 info install foundationpress@5.5.2
28 info postinstall foundationpress@5.5.2
29 verbose unsafe-perm in lifecycle true
30 info foundationpress@5.5.2 Failed to exec postinstall script
31 verbose stack Error: foundationpress@5.5.2 postinstall: bower install && grunt build
31 verbose stack Exit status 1
31 verbose stack at EventEmitter. (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\lifecycle.js:213:16)
31 verbose stack at EventEmitter.emit (events.js:110:17)
31 verbose stack at ChildProcess. (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\spawn.js:14:12)
31 verbose stack at ChildProcess.emit (events.js:110:17)
31 verbose stack at maybeClose (child_process.js:1008:16)
31 verbose stack at Process.ChildProcess._handle.onexit (child_process.js:1080:5)
32 verbose pkgid foundationpress@5.5.2
33 verbose cwd C:\Users\Daniel\Documents\Websites\www.turningpoint.dev\wp-content\themes\FoundationPressTheme
34 error Windows_NT 6.1.7601
35 error argv "C:\Program Files (x86)\nodejs\node.exe" "C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js" "install"
36 error node v0.12.0
37 error npm v2.5.1
38 error code ELIFECYCLE
39 error foundationpress@5.5.2 postinstall: bower install && grunt build
39 error Exit status 1
40 error Failed at the foundationpress@5.5.2 postinstall script 'bower install && grunt build'.
40 error This is most likely a problem with the foundationpress package,
40 error not with npm itself.
40 error Tell the author that this fails on your system:
40 error bower install && grunt build
40 error You can get their info via:
40 error npm owner ls foundationpress
40 error There is likely additional logging output above.
41 verbose exit [ 1, true ]

@olefredrik
Copy link
Owner

Which versions of node and npm are you using?

I'm on Node v0.12.0 and npm 2.5.1.

(type node-v and npm-v in your terminal to find your version number). If you're on an older version, that might be the issue.

@danieldvos
Copy link
Author

Same versions as you: Node v0.12.0 and npm 2.5.1

Any idea what these mean in the error log?

29 verbose unsafe-perm in lifecycle true

38 error code ELIFECYCLE

@olefredrik
Copy link
Owner

I have no idea. Are you able to install grunt as a global dependency and run the grunt watch task?

I see that you're not alone having problems with node post install, but unfortunately I don't have the solution to the problem.

@ghost
Copy link

ghost commented Jul 26, 2019

npm cache clean --force
rm -rf node_modules
npm install
npm run dev
npm run watch

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants