check-commit: fix the exit status
should work this time...
This commit is contained in:
parent
ff33690e75
commit
f6e8f18a9a
@ -21,18 +21,20 @@ fi
|
|||||||
|
|
||||||
# First test for a whole repo
|
# First test for a whole repo
|
||||||
# This will likely exit firh error, because repoman
|
# This will likely exit firh error, because repoman
|
||||||
# has to download some files ( metadata.xsd)
|
# has to download some files (metadata.xsd)
|
||||||
# We do that so we can truthfully test the actual latest commit
|
# We do that so we can truthfully test the actual latest commit
|
||||||
|
echo ">>> Starting full test"
|
||||||
repoman -Idix
|
repoman -Idix
|
||||||
|
pkgcheck scan
|
||||||
|
|
||||||
|
|
||||||
|
echo ">>> Starting latest commit test"
|
||||||
|
|
||||||
test_success=true
|
test_success=true
|
||||||
|
|
||||||
|
|
||||||
# Use pkgchek
|
# Use pkgchek
|
||||||
pkgcheck scan --commits || test_success=false
|
pkgcheck scan --commits || test_success=false
|
||||||
|
|
||||||
|
|
||||||
# Iterate through changed files in last commit
|
# Iterate through changed files in last commit
|
||||||
# For each of these use dirname to change directory
|
# For each of these use dirname to change directory
|
||||||
# to the one where the changed file resides
|
# to the one where the changed file resides
|
||||||
@ -51,4 +53,10 @@ do
|
|||||||
done
|
done
|
||||||
|
|
||||||
# If any of the QA tools fail the test will fail
|
# If any of the QA tools fail the test will fail
|
||||||
[ ${test_success} = false ] && ( echo "Exiting with failure due to previous errors..."; exit 1 )
|
if [ ${test_success} = false ]
|
||||||
|
then
|
||||||
|
echo ">>> Exiting with failure due to previous errors..."
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
Loading…
x
Reference in New Issue
Block a user