diff options
author | John Ankarström <john@ankarstrom.se> | 2021-07-27 17:54:28 +0200 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2021-07-27 17:54:28 +0200 |
commit | ba8a3ef6524e9dc6267a036ee33a9fcd01571d13 (patch) | |
tree | c06eb6f05b63d4e9ee1692e44464bd7f9a709277 | |
parent | c842c23a067977a1ec9edb28e1feb062c1b08a41 (diff) | |
download | patches-ba8a3ef6524e9dc6267a036ee33a9fcd01571d13.tar.gz |
pkgpatchex: Exit if patch fails
-rwxr-xr-x | bin/pkgpatchex | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/bin/pkgpatchex b/bin/pkgpatchex index c475a4b..0c94b8f 100755 --- a/bin/pkgpatchex +++ b/bin/pkgpatchex @@ -1,7 +1,13 @@ -#!/bin/sh +#!/bin/sh -ef -# pkgpatchall -- apply all patches +# pkgpatchex -- apply all patches -ls "$(whereispatch -i)"/patch-* | while read -r patch; do - pkgpatch <"$patch" +IFS=' +' + +for patch in $(find $(whereispatch -i) -name 'patch-*' -type f); do + echo "${0##*/}: applying $(basename $patch)" + pkgpatch <$patch done + +pkgclear 2>/dev/null || true |