mirror of
https://codeberg.org/librewolf/source.git
synced 2025-01-18 02:12:30 -05:00
improved error handling
This commit is contained in:
parent
6edbe91fd6
commit
ba09c9f2bc
1 changed files with 14 additions and 2 deletions
|
@ -12,7 +12,7 @@ fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
failed_patches=
|
||||||
|
|
||||||
echo "Removing '$tmpdir'..."
|
echo "Removing '$tmpdir'..."
|
||||||
rm -rf $tmpdir
|
rm -rf $tmpdir
|
||||||
|
@ -38,6 +38,8 @@ for i in $(cat ../../assets/patches.txt); do
|
||||||
done
|
done
|
||||||
s=$s
|
s=$s
|
||||||
if [ ! -z "$s" ]; then
|
if [ ! -z "$s" ]; then
|
||||||
|
s=$(echo $i)
|
||||||
|
failed_patches="$failed_patches [$s]"
|
||||||
echo ""
|
echo ""
|
||||||
for k in $s; do
|
for k in $s; do
|
||||||
echo "--> $s:"
|
echo "--> $s:"
|
||||||
|
@ -53,4 +55,14 @@ cd ../..
|
||||||
echo ""
|
echo ""
|
||||||
echo "Removing '$tmpdir'..."
|
echo "Removing '$tmpdir'..."
|
||||||
rm -rf $tmpdir
|
rm -rf $tmpdir
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
if [ ! -z "$failed_patches" ]; then
|
||||||
|
echo $failed_patches
|
||||||
|
echo ""
|
||||||
|
echo "error: Some patches failed!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
echo "success: All patches where applied successfully."
|
||||||
exit 0
|
exit 0
|
||||||
|
fi
|
||||||
|
|
Loading…
Add table
Reference in a new issue