liferay / liferay-theme-tasks

A set of tasks for building and deploying Liferay Portal themes.
18 stars 24 forks source link

Liferay 7 - Gulp task Upgrade - spawn npm ENOENT error #23

Closed moyadf closed 8 years ago

moyadf commented 8 years ago

When execute the gulp task upgrade , for replace css files to sass, ask (Do you want to rename custom.css to _custom.scss ? ) , but the console show me the following error

C:\Users\DavidFernando\theme-L7\portal-osisanitas-theme>gulp upgrade
[16:16:15] Using gulpfile ~\theme-L7\portal-osisanitas-theme\gulpfile.js
[16:16:15] Starting 'upgrade'...
[16:16:15] Starting 'upgrade:create-backup-files'...
[16:16:19] Finished 'upgrade:create-backup-files' after 3.59 s
[16:16:19] Starting 'upgrade:black-list'...
[16:16:19] Finished 'upgrade:black-list' after 62 ms
[16:16:19] Starting 'upgrade:replace-compass'...
[16:16:19] Finished 'upgrade:replace-compass' after 271 ms
[16:16:19] Starting 'upgrade:convert-bootstrap'...
Wrote file: src/css/custom.css
Wrote file: src/css/osisanitas_responsive.css
Wrote file: src/css/osisanitas.css
Wrote file: src/css/portlet.css
[16:16:20] Finished 'upgrade:convert-bootstrap' after 656 ms
[16:16:20] Starting 'upgrade:config'...
[16:16:20] Finished 'upgrade:config' after 44 ms
[16:16:20] Starting 'upgrade:rename-core-files'...
[?] Do you want to rename custom.css to _custom.scss? Yes
[?] Do you want to rename main.css to main.scss? Yes
[?] Do you want to rename portlet.css to _portlet.scss? Yes
[16:16:29] Finished 'upgrade:rename-core-files' after 8.5 s
[16:16:29] Starting 'upgrade:create-css-diff'...
[16:16:29] Finished 'upgrade:create-css-diff' after 391 ms
[16:16:29] Starting 'upgrade:dependencies'...
events.js:141
      throw er; // Unhandled 'error' event
      ^

Error: spawn npm ENOENT
  at exports._errnoException (util.js:874:11)
  at Process.ChildProcess._handle.onexit (internal/child_process.js:178:32)
  at onErrorNT (internal/child_process.js:344:16)
  at doNTCallback2 (node.js:441:9)
  at process._tickCallback (node.js:355:17)

I'm using version 4.2.2 nodejs , yeoman - gulp (3.9.1) and version 3.9.0 of npm

how could fix this error?

Thanks for your help.

robframpton commented 8 years ago

Hello @moyadf

This was a regression bug with Windows environments. v1.2.2 was just published which addresses this issue.

Please run gulp upgrade:revert before you attempt to run the upgrade task again, as the upgrade task only partially completed when you ran into this error.