maizzle / maizzle-php

Jigsaw-based PHP build system for rapid HTML email development with Tailwind CSS.
https://jigsaw.maizzle.com
MIT License
304 stars 6 forks source link

npm errors on 'npm install' #37

Closed zebrastribe closed 4 years ago

zebrastribe commented 4 years ago

Hi I cannot install the dependencies with 'npm install': win10 Composer version 1.10.5 node version14.0.0

get a lot of errors:


12 Warning(s)
233 Error(s)

Time Elapsed 00:00:20.21 gyp ERR! build error gyp ERR! stack Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe failed with exit code: 1 gyp ERR! stack at ChildProcess.onExit (C:\Users\jkn\OneDrive\dev\sites\kbhliv-mailmodul\app\public\wp-content\plugins\mailmodul\includes\dev\template\node_modules\node-gyp\lib\build.js:258:23) gyp ERR! stack at ChildProcess.emit (events.js:315:20) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:276:12) gyp ERR! System Windows_NT 10.0.18363 gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\jkn\OneDrive\dev\sites\kbhliv-mailmodul\app\public\wp-content\plugins\mailmodul\includes\dev\template\node_modules\node-gyp\bin\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library=" gyp ERR! cwd C:\Users\jkn\OneDrive\dev\sites\kbhliv-mailmodul\app\public\wp-content\plugins\mailmodul\includes\dev\template\node_modules\node-sass gyp ERR! node -v v14.0.0 gyp ERR! node-gyp -v v3.6.2 gyp ERR! not ok Build failed with error code: 1 npm WARN rollback Rolling back node-pre-gyp@0.10.0 failed (this is probably harmless): EPERM: operation not permitted, lstat 'C:\Users\jkn\OneDrive\dev\sites\kbhliv-mailmodul\app\public\wp-content\plugins\mailmodul\includes\dev\template\node_modules\fsevents\node_modules' npm WARN ajv-keywords@3.2.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! node-sass@4.9.0 postinstall: node scripts/build.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the node-sass@4.9.0 postinstall script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\jkn\AppData\Roaming\npm-cache_logs\2020-04-26T15_16_37_559Z-debug.log

cossssmin commented 4 years ago

Yeah, node-sass is failing, you'll need to install Windows Build Tools - see this SO thread: https://stackoverflow.com/a/46977724/963539

But keep in mind that I'm no longer supporting this Maizzle version - you might want to use the Node.js one: https://maizzle.com

zebrastribe commented 4 years ago

Thank you, I will let go of the php version. The node.js version works great. I plan to use maizzle in a wordpress plugin so I will convert the build version of the layout into php. Is there a way using the templates, paritals etc without node.js? (noob, I know)

cossssmin commented 4 years ago

You mean the file extension? You can do that in the config:

module.exports = {
  build: {
    destination: {
      path: 'build_production',
      extension: 'php',
    },
    // ...
  }
}

If your plugin will be public, I'd love to see it in action 👍

zebrastribe commented 4 years ago

Yeah, configuring the file extension sounds like a good place to start. It is a bit small scope plugin for my company. When the plugin is done I will sent you a heads up :-) I was hoping to get the design of the email seperate from the logic like a templated solution. The plugin will use ACF and MailChimp API.