From a4b54cccb30af287aa621953ff0021d10c3abecc Mon Sep 17 00:00:00 2001 From: Jakob Ackermann Date: Fri, 13 Aug 2021 14:48:52 +0200 Subject: [PATCH] Merge pull request #4686 from overleaf/jpa-copybara [misc] set up copybara sync for monorepo GitOrigin-RevId: 4a0a0263fbc42833f88417f95231966dfa80341e --- services/web/bin/invoke-copybara | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100755 services/web/bin/invoke-copybara diff --git a/services/web/bin/invoke-copybara b/services/web/bin/invoke-copybara deleted file mode 100755 index ee1bc93f52..0000000000 --- a/services/web/bin/invoke-copybara +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash - -KNOWN_HOSTS=/root/.ssh/known_hosts - -if [[ "$BRANCH_NAME" == "master" && "$COPYBARA" == "run" ]]; then - set -e - chmod -R 0600 /root/.ssh - ssh-keyscan github.com > $KNOWN_HOSTS - ssh-keygen -lf $KNOWN_HOSTS | grep "SHA256:nThbg6kXUpJWGl7E1IGOCspRomTxdCARLviKw6E5SY8 github.com" - git config --global user.name Copybot - git config --global user.email copybot@overleaf.com - set +e - copybara --git-committer-email=copybot@overleaf.com --git-committer-name=Copybot - COPYBARA_EXIT_CODE=$? - # Exit codes are documented in java/com/google/copybara/util/ExitCode.java - # 0 is success, 4 is no-op (i.e. no change), anything else is an error - if [[ $COPYBARA_EXIT_CODE -eq 0 || $COPYBARA_EXIT_CODE -eq 4 ]]; then - exit 0 - else - exit $COPYBARA_EXIT_CODE - fi -fi