1#!/bin/sh 2# 3# Copyright (c) 2019 Linaro Limited 4# 5# SPDX-License-Identifier: Apache-2.0 6# 7 8remote=$1 9url=$2 10local_ref=$3 11local_sha=$4 12remote_ref=$5 13remote_sha=$6 14z40=0000000000000000000000000000000000000000 15 16set -e exec 17 18echo "Run push " 19 20if [ "$local_sha" = $z40 ] 21then 22 # Handle delete 23 : 24else 25 # At each (forced) push, examine all commits since $remote/main 26 base_commit=`git rev-parse $remote/main` 27 range="$base_commit..$local_sha" 28 29 echo "Perform check patch" 30 ${ZEPHYR_BASE}/scripts/checkpatch.pl --git $range 31fi 32