From 1b32d9b70e71406b96b738db58b8d45ff7633502 Mon Sep 17 00:00:00 2001 From: Anup Date: Wed, 2 Aug 2017 11:41:57 +0530 Subject: [PATCH] fix: check node version --- check.js | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/check.js b/check.js index 29d8a96ec..b54dd66ba 100644 --- a/check.js +++ b/check.js @@ -11,7 +11,7 @@ module.exports = function () { const errorMessage = colors.yellow(` - ⚠️ preact-cli requires at least node@${minimum}! + ⚠️ preact-cli requires at least node@${minimum}! You have node@${version} `); diff --git a/package.json b/package.json index 077e6f224..93ee073dd 100644 --- a/package.json +++ b/package.json @@ -16,7 +16,7 @@ "pretest": "npm run -s build && rimraf ./tests/output", "test": "jest", "posttest": "rimraf ./tests/output", - "postinstall": "node check.js", + "postinstall": "node -p 'require(\"./check.js\")()'", "test:build": "babel-node src build --cwd examples/root", "test:serve": "npm run -s test:build && babel-node src serve --port 3000 --cwd examples/root", "test:serve:config": "npm run -s test:build && babel-node src serve --server config --cwd examples/root",