1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-12 14:14:48 +02:00

core: fix test of Debian patches when there are no patches

This commit is contained in:
Sébastien Helleu
2024-09-08 09:27:50 +02:00
parent bb83685ac6
commit df4acd5d3d
+7 -5
View File
@@ -109,11 +109,13 @@ test_patches ()
patches_ok=0
patches_error=0
for file in "${root_dir}"/tools/debian/patches/*.patch; do
echo "=== Testing patch ${file} ==="
if git apply --check "${file}"; then
patches_ok=$((patches_ok+1))
else
patches_error=$((patches_error+1))
if [ -f "${file}" ]; then
echo "=== Testing patch ${file} ==="
if git apply --check "${file}"; then
patches_ok=$((patches_ok+1))
else
patches_error=$((patches_error+1))
fi
fi
done
echo "Patches: ${patches_ok} OK, ${patches_error} in error."