From fd3f316e09534348070143fa8f6f34e9944a91c1 Mon Sep 17 00:00:00 2001 From: fr1n63 Date: Fri, 1 Dec 2017 17:10:05 +0000 Subject: [PATCH] Add || exit 0 to opencollective https://github.com/opencollective/opencollective-postinstall Why || exit 0 in scripts.postinstall? Since we are adding the dependency in devDependencies, the script ./node_modules/.bin/opencollective-postinstall won't be installed in production. Therefore, the postinstall script will return an error and will interrupt the npm install process. Adding || exit 0 makes sure that this postinstall script always returns true. --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 8fdc90c4..05f0aa68 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "flow": "flow", "lint": "eslint ./src", "prepublish": "npm run clean && npm run build", - "postinstall": "postinstall-build dist && opencollective postinstall", + "postinstall": "postinstall-build dist && opencollective postinstall || exit 0", "test-cli": "node ./bin/test.js", "tests-packager": "cd tests && npm run start", "tests-npm-install": "cd tests && npm install",