From 2ec3866f7c1bb0963bf783df0fc4605ef29c4908 Mon Sep 17 00:00:00 2001 From: Andrey Lushnikov Date: Fri, 18 Mar 2022 15:48:10 -0600 Subject: [PATCH] devops: update electron build tools (#12891) --- browser_patches/chromium/goma.sh | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/browser_patches/chromium/goma.sh b/browser_patches/chromium/goma.sh index 9a7a77cf59..77503160b4 100755 --- a/browser_patches/chromium/goma.sh +++ b/browser_patches/chromium/goma.sh @@ -5,8 +5,21 @@ set -x trap "cd $(pwd -P)" EXIT cd "$(dirname "$0")" +ELECTRON_BUILD_TOOLS_REQUIRED_VERSION=6ba8962529c37727a778691b89c92ab0eb1d9d87 +if [[ -d ./electron-build-tools ]]; then + cd ./electron-build-tools + # Make sure required commit is part of electron-build-tools. + if ! git merge-base --is-ancestor "${ELECTRON_BUILD_TOOLS_REQUIRED_VERSION}" HEAD; then + cd .. + rm -rf ./electron-build-tools + echo "Updating electron-build-tools" + else + cd .. + fi +fi + if [[ ! -d ./electron-build-tools ]]; then - git clone --single-branch --branch master https://github.com/electron/build-tools/ electron-build-tools + git clone --single-branch --branch main https://github.com/electron/build-tools/ electron-build-tools cd electron-build-tools npm install mkdir -p third_party