From 630886ea6f2b965e0ca870c25f80f279bd9bb62a Mon Sep 17 00:00:00 2001 From: Christopher Allen Date: Wed, 6 Jul 2022 23:09:19 +0100 Subject: [PATCH] fix(build): Don't depend on execSync running bash (#6262) For some reason on Github CI servers execSync uses /bin/sh, which is (on Ubuntu) dash rather than bash, and does not understand the pipefail option. So remove the grep pipe on stderr and just discard all error output at all. This is not ideal as errors in test deps will go unreported AND not even cause test failure, but it's not clear that it's worth investing more time to fix this at the moment. --- scripts/gulpfiles/build_tasks.js | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/scripts/gulpfiles/build_tasks.js b/scripts/gulpfiles/build_tasks.js index ac037ff03..4ed0d6232 100644 --- a/scripts/gulpfiles/build_tasks.js +++ b/scripts/gulpfiles/build_tasks.js @@ -343,18 +343,14 @@ function buildDeps(done) { const args = roots.map(root => `--root '${root}' `).join(''); execSync( - `set -o pipefail; \ - (closure-make-deps ${args} >'${DEPS_FILE}') 2>&1 \ - | (grep -v '^WARNING in' ; true)`, + `closure-make-deps ${args} 2>/dev/null >'${DEPS_FILE}'`, {stdio: 'inherit'}); // Use grep to filter out the entries that are already in deps.js. const testArgs = testRoots.map(root => `--root '${root}' `).join(''); execSync( - `set -o pipefail; \ - (closure-make-deps ${testArgs} | grep 'tests/mocha' \ - > '${TEST_DEPS_FILE}') 2>&1 \ - | (grep -v '^WARNING in' ; true)`, + `closure-make-deps ${testArgs} 2>/dev/null \ + | grep 'tests/mocha' > '${TEST_DEPS_FILE}'`, {stdio: 'inherit'}); done(); }