From c6848ec0e16f193a06195921c669e2bf9c014c5c Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Fri, 13 Sep 2013 17:50:45 -0400 Subject: libremakepkg: I can't believe committed my debug statements. --- src/chroot-tools/libremakepkg | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/chroot-tools/libremakepkg') diff --git a/src/chroot-tools/libremakepkg b/src/chroot-tools/libremakepkg index 22e7a7f..c979b71 100755 --- a/src/chroot-tools/libremakepkg +++ b/src/chroot-tools/libremakepkg @@ -61,12 +61,12 @@ exit_copy() { run_hook() { local hookname=$1; shift local hookvar="hook_${hookname}[@]" + local fails=() - msg "Running hook: %s" "$hookname" for hook in "${!hookvar}"; do - msg2 'hook: %s' "$hook" "$hook" "$@" || { error "result: %s" $?; fails+=("$hook"); } done + if [[ ${#fails[@]} -gt 0 ]]; then error "Failure(s) in %s: %s" "$hookname" "${fails[*]}" return 1 @@ -236,12 +236,10 @@ main() { # Build trap "exit_copy '$copydir' '$LIBREUSER'" EXIT - warning 'Entering build...' build "$copydir" "${makepkg_args[@]}" + # Post-build - warning 'Entering hook check_pkg...' run_hook check_pkg - warning 'Entering add_to_local_repo ...' add_to_local_repo "$copydir" "$copydir"/pkgdest/*.pkg.tar* } -- cgit v1.2.3-54-g00ecf