Menu icon Foundation
NPM Run Build or Foundation Build fails

I'm working on an email project and want to run the build task so all the css gets inlined. running foundation watch or npm start and everything is fine. However run npm run build or foundation build and it errors out.

 

I've deleted node_modules and then run npm install and tried again but nothing changes. Not sure what to do now.

 

Here is my npm-debug.log file

 

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 [email protected]

3 info using [email protected]

4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]

5 info prebuild [email protected]

6 info build [email protected]

7 verbose unsafe-perm in lifecycle true

8 info [email protected] Failed to exec build script

9 verbose stack Error: [email protected] build: `gulp --production`

9 verbose stack Exit status 1

9 verbose stack     at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:217:16)

9 verbose stack     at emitTwo (events.js:87:13)

9 verbose stack     at EventEmitter.emit (events.js:172:7)

9 verbose stack     at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:24:14)

9 verbose stack     at emitTwo (events.js:87:13)

9 verbose stack     at ChildProcess.emit (events.js:172:7)

9 verbose stack     at maybeClose (internal/child_process.js:829:16)

9 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)

10 verbose pkgid [email protected]

11 verbose cwd C:\Users\Sean\Desktop\yo inky\Caffeine-Newsletter

12 error Windows_NT 10.0.14393

13 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "build"

14 error node v4.5.0

15 error npm  v2.15.9

16 error code ELIFECYCLE

17 error [email protected] build: `gulp --production`

17 error Exit status 1

18 error Failed at the [email protected] build script 'gulp --production'.

18 error This is most likely a problem with the foundation-emails-template package,

18 error not with npm itself.

18 error Tell the author that this fails on your system:

18 error     gulp --production

18 error You can get information on how to open an issue for this project with:

18 error     npm bugs foundation-emails-template

18 error Or if that isn't available, you can get their info via:

18 error

18 error     npm owner ls foundation-emails-template

18 error There is likely additional logging output above.

19 verbose exit [ 1, true ]

 

build fail

I'm working on an email project and want to run the build task so all the css gets inlined. running foundation watch or npm start and everything is fine. However run npm run build or foundation build and it errors out.

 

I've deleted node_modules and then run npm install and tried again but nothing changes. Not sure what to do now.

 

Here is my npm-debug.log file

 

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 [email protected]

3 info using [email protected]

4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]

5 info prebuild [email protected]

6 info build [email protected]

7 verbose unsafe-perm in lifecycle true

8 info [email protected] Failed to exec build script

9 verbose stack Error: [email protected] build: `gulp --production`

9 verbose stack Exit status 1

9 verbose stack     at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:217:16)

9 verbose stack     at emitTwo (events.js:87:13)

9 verbose stack     at EventEmitter.emit (events.js:172:7)

9 verbose stack     at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:24:14)

9 verbose stack     at emitTwo (events.js:87:13)

9 verbose stack     at ChildProcess.emit (events.js:172:7)

9 verbose stack     at maybeClose (internal/child_process.js:829:16)

9 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)

10 verbose pkgid [email protected]

11 verbose cwd C:\Users\Sean\Desktop\yo inky\Caffeine-Newsletter

12 error Windows_NT 10.0.14393

13 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "build"

14 error node v4.5.0

15 error npm  v2.15.9

16 error code ELIFECYCLE

17 error [email protected] build: `gulp --production`

17 error Exit status 1

18 error Failed at the [email protected] build script 'gulp --production'.

18 error This is most likely a problem with the foundation-emails-template package,

18 error not with npm itself.

18 error Tell the author that this fails on your system:

18 error     gulp --production

18 error You can get information on how to open an issue for this project with:

18 error     npm bugs foundation-emails-template

18 error Or if that isn't available, you can get their info via:

18 error

18 error     npm owner ls foundation-emails-template

18 error There is likely additional logging output above.

19 verbose exit [ 1, true ]

 

Corey Schaaf over 2 years ago

It might be some of the dependencies are failing.  I usually take the step you've already done when this fails.  Out of curiosity - have you tried a npm install for rebuilding the node-modules folder? 

 

Rafi Benkual over 2 years ago

It sounds like you rebuilt the node modules folder. What version of node are you running? node -v is the command.

Sean Smith over 2 years ago

I'm on Node 4.5.0