From 250f2c5663d885901f5a80b93115f2b866457840 Mon Sep 17 00:00:00 2001 From: Cheng Liu Date: Mon, 26 Aug 2024 22:13:19 -0700 Subject: [PATCH] fix: website build --- apps/website/build.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/apps/website/build.js b/apps/website/build.js index f13a831..0d91d10 100644 --- a/apps/website/build.js +++ b/apps/website/build.js @@ -1,7 +1,18 @@ const { spawnSync } = require('child_process'); function runCommand(command, args) { - const result = spawnSync(command, args, { stdio: 'inherit', shell: true }); + const result = spawnSync(command, args, { + stdio: 'inherit', + shell: true, + env: { + ...process.env, + // Suppress the "Browserslist: caniuse-lite is outdated" warning. Although the warning is + // potentially useful, the check is performed in a way that is nondeterministic and can cause + // Rush pipelines to fail. Moreover, the outdated version is often irrelevant and/or nontrivial + // to upgrade. See this thread for details: https://github.com/microsoft/rushstack/issues/2981 + BROWSERSLIST_IGNORE_OLD_DATA: '1' + } + }); if (result.error) { console.log(result.error.message); process.exitCode = 1;