edition-node-grunt icon indicating copy to clipboard operation
edition-node-grunt copied to clipboard

Installation as dependency doesn't work

Open Schleuse opened this issue 9 years ago • 5 comments

I am using Edition Node Grunt v1.1.0 on Windows, with Node v6.5.0.

Expected Behavior

Installation as dependecy works

Actual Behavior

postinstall script throws Exception after installation

Steps to Reproduce
mkdir test
cd test
npm init
npm install --save edition-node-grunt
npm WARN deprecated [email protected]: ReDoS vulnerability parsing Set-Cookie https://nodesecurity.io/advisories/130
npm WARN prefer global [email protected] should be installed with -g

> [email protected] postinstall C:\Users\schleuse\Desktop\test\node_modules\edition-node-grunt
> node node_modules/patternlab-node/core/scripts/postinstall.js

module.js:457
    throw err;
    ^

Error: Cannot find module 'C:\Users\schleuse\Desktop\test\node_modules\edition-node-grunt\node_modules\patternlab-node\core\scripts\postinstall.js'
    at Function.Module._resolveFilename (module.js:455:15)
    at Function.Module._load (module.js:403:25)
    at Module.runMain (module.js:590:10)
    at run (bootstrap_node.js:394:7)
    at startup (bootstrap_node.js:149:9)
    at bootstrap_node.js:509:3
npm WARN optional Skipping failed optional dependency /chokidar/fsevents:
npm WARN notsup Not compatible with your operating system or architecture: [email protected]
npm WARN [email protected] No description
npm WARN [email protected] No repository field.
npm ERR! Windows_NT 10.0.14393
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\schleuse\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "install" "--save" "edition-node-grunt"
npm ERR! node v6.5.0
npm ERR! npm  v3.10.6
npm ERR! code ELIFECYCLE

npm ERR! [email protected] postinstall: `node node_modules/patternlab-node/core/scripts/postinstall.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'node node_modules/patternlab-node/core/scripts/postinstall.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the edition-node-grunt package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node node_modules/patternlab-node/core/scripts/postinstall.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs edition-node-grunt
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls edition-node-grunt
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     C:\Users\schleuse\Desktop\test\npm-debug.log

npm-debug.txt

Schleuse avatar Sep 07 '16 12:09 Schleuse

Just to clarify - this isn't supposed to be working right now. For the time being, the only way to use Pattern Lab Node Editions is as standalone projects.

You can still download the package or clone the repo and run npm install, but running npm install edition-node-grunt will likely not work until the CLI is more fully baked as part of https://github.com/pattern-lab/patternlab-node/milestone/20

bmuenzenmeyer avatar Sep 23 '16 15:09 bmuenzenmeyer

I guess this could be closed by adding some informative text that I would have read and been very thankfull for the time I would have saved ;-) But please keep up the good work and thank you.

PocketNinjaDesign avatar Sep 26 '16 22:09 PocketNinjaDesign

I'm surprised every time I'm remembered about this strange distribution strategy. I really don't get it, why nobody thought of the scenario, that somebody would like to add patternlab as a devDependency to a frontend package and generate the patternlab from the CSS from the package and the patterns without copying all the stuff from the NPM package and forcing the users to make manual updates instead of allowing updates through NPM. The patternlab CLI doesn't help in this case. I just want to put my patterns somewhere and give grunt the path to the pattern directory and the CSS. It could be so simple.

DaSchTour avatar Feb 07 '17 17:02 DaSchTour

@DaSchTour comments like this do nothing but dishearten maintainers. We are actively working (almost exclusively by donating our free time) on making PL perform better under these exact use cases and care very much about getting it right.

bmuenzenmeyer avatar Feb 07 '17 17:02 bmuenzenmeyer

@DaSchTour I'd also like to point you to https://github.com/pattern-lab/patternlab-node-cli/wiki/Use-Cases which is currently under construction as a place to document all use cases we want to cover with PL Node 3.0

I welcome your input there

bmuenzenmeyer avatar Feb 07 '17 17:02 bmuenzenmeyer