Fix computation of the merge base for git-validation
CIRRUS_BASE_SHA is a valid commit, but it might not be
a parent of the current PR, so it might not be available,
making a ${CIRRUS_BASE_SHA}..$something git commit range expressions
fail.
Compare https://github.com/cirruslabs/cirrus-ci-docs/issues/1279 .
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
This commit is contained in:
parent
78f4258b2b
commit
e584bbc882
|
|
@ -128,6 +128,7 @@ lint_task:
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get install -y libbtrfs-dev libsubid-dev
|
apt-get install -y libbtrfs-dev libsubid-dev
|
||||||
test_script: |
|
test_script: |
|
||||||
|
[ -n "${CIRRUS_BASE_SHA}" ] && git fetch origin ${CIRRUS_BASE_SHA} # Make ${CIRRUS_BASE_SHA} resolvable for git-validation
|
||||||
make TAGS=regex_precompile local-validate
|
make TAGS=regex_precompile local-validate
|
||||||
make lint
|
make lint
|
||||||
make clean
|
make clean
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue