blob: 1cc6d020b185ce37adcd84bd67a0349d8d300c48 (
plain)
1
2
3
4
5
6
7
|
#!/bin/bash
# wraps mock so that it gives a proper error return if it fails.
set -o pipefail
( mock "$@" 2>&1 | tee rpms/mock.out ) || exit $?
# now grep through mock.out to see if an ERROR was flagged.
grep -q "^ERROR:" rpms/mock.out && exit 1 # fail!
exit 0
|