Silents errors when running copy-sources

Summary:
Being a environment test, `npm run is-monolithic` is expected to fail when pulling the package from npm and to succeed when pulling it from github. Unfortunately, when returning false, npm will throw a tantrum by default if not explicitely disabled. It's not a hard failure, the build still complete, but it's better this way.
Closes https://github.com/facebook/yoga/pull/362

Reviewed By: gkassabli

Differential Revision: D4480608

Pulled By: emilsjolander

fbshipit-source-id: 0832a2158647f49b5230e2f658997f94774cec5b
This commit is contained in:
Maël Nison
2017-01-30 06:15:18 -08:00
committed by Facebook Github Bot
parent 625dc4bf44
commit b87fc217df

View File

@@ -19,7 +19,7 @@
"emcc-path": "emcc-path", "emcc-path": "emcc-path",
"is-monolithic": "test \"$(basename \"$(pwd)\")\" = javascript", "is-monolithic": "test \"$(basename \"$(pwd)\")\" = javascript",
"copy-sources": "! npm -- run is-monolithic || (rsync -r --checksum --delete ../yoga/ sources/yoga/)", "copy-sources": "! npm -s -- run is-monolithic || (rsync -r --checksum --delete ../yoga/ sources/yoga/)",
"build:node": "npm -- run copy-sources && npm -- run node-gyp configure build", "build:node": "npm -- run copy-sources && npm -- run node-gyp configure build",
"build:browser": "npm -- run copy-sources && npm -- run node-gyp configure build --asmjs=1", "build:browser": "npm -- run copy-sources && npm -- run node-gyp configure build --asmjs=1",