mirror of
https://github.com/profanity-im/profanity.git
synced 2024-12-04 14:46:46 -05:00
Merge pull request #1465 from wstrm/fix-print-logs-in-ci
Print logs on error in CI
This commit is contained in:
commit
19dc630ce8
15
ci-build.sh
15
ci-build.sh
@ -1,8 +1,19 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
log_content()
|
||||||
|
{
|
||||||
|
echo
|
||||||
|
echo "Content of $1:"
|
||||||
|
cat "$1"
|
||||||
|
}
|
||||||
|
|
||||||
error_handler()
|
error_handler()
|
||||||
{
|
{
|
||||||
ERR_CODE=$?
|
ERR_CODE=$?
|
||||||
|
|
||||||
|
log_content ./config.log
|
||||||
|
log_content ./test-suite.log
|
||||||
|
|
||||||
echo
|
echo
|
||||||
echo "Error ${ERR_CODE} with command '${BASH_COMMAND}' on line ${BASH_LINENO[0]}. Exiting."
|
echo "Error ${ERR_CODE} with command '${BASH_COMMAND}' on line ${BASH_LINENO[0]}. Exiting."
|
||||||
echo
|
echo
|
||||||
@ -114,10 +125,6 @@ do
|
|||||||
$MAKE CC="${CC}"
|
$MAKE CC="${CC}"
|
||||||
$MAKE check
|
$MAKE check
|
||||||
|
|
||||||
if [ $? -eq 1 ]; then
|
|
||||||
cat ./test-suite.log
|
|
||||||
fi
|
|
||||||
|
|
||||||
./profanity -v
|
./profanity -v
|
||||||
$MAKE clean
|
$MAKE clean
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user