From 93504da3a932f33126545ebc9383f695a6efe51e Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Fri, 18 Dec 2020 12:17:25 +0200 Subject: ci: Fix COMMIT_RANGE variable value for PRs --- ci/lint/05_before_script.sh | 9 --------- ci/lint/06_script.sh | 6 ++---- ci/lint_run_all.sh | 1 - 3 files changed, 2 insertions(+), 14 deletions(-) delete mode 100755 ci/lint/05_before_script.sh diff --git a/ci/lint/05_before_script.sh b/ci/lint/05_before_script.sh deleted file mode 100755 index 8e5a177b01..0000000000 --- a/ci/lint/05_before_script.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env bash -# -# Copyright (c) 2018-2019 The Bitcoin Core developers -# Distributed under the MIT software license, see the accompanying -# file COPYING or http://www.opensource.org/licenses/mit-license.php. - -export LC_ALL=C - -git fetch diff --git a/ci/lint/06_script.sh b/ci/lint/06_script.sh index ba582e7bf6..8aa775c28a 100755 --- a/ci/lint/06_script.sh +++ b/ci/lint/06_script.sh @@ -7,12 +7,10 @@ export LC_ALL=C if [ -n "$CIRRUS_PR" ]; then - # CIRRUS_PR will be present in a Cirrus environment. For builds triggered - # by a pull request this is the name of the branch targeted by the pull request. - # https://cirrus-ci.org/guide/writing-tasks/#environment-variables - COMMIT_RANGE="$CIRRUS_BRANCH..HEAD" + COMMIT_RANGE="$CIRRUS_BASE_SHA..HEAD" test/lint/commit-script-check.sh $COMMIT_RANGE fi +export COMMIT_RANGE # This only checks that the trees are pure subtrees, it is not doing a full # check with -r to not have to fetch all the remotes. diff --git a/ci/lint_run_all.sh b/ci/lint_run_all.sh index 2623f46828..e383ffd9d6 100755 --- a/ci/lint_run_all.sh +++ b/ci/lint_run_all.sh @@ -8,5 +8,4 @@ export LC_ALL=C.UTF-8 set -o errexit; source ./ci/test/00_setup_env.sh set -o errexit; source ./ci/lint/04_install.sh -set -o errexit; source ./ci/lint/05_before_script.sh set -o errexit; source ./ci/lint/06_script.sh -- cgit v1.2.3