From b175fd43eb5e44d8a0a9cca08985879983677719 Mon Sep 17 00:00:00 2001 From: Baptiste Augrain Date: Sat, 14 Aug 2021 22:59:32 +0200 Subject: [PATCH] fix: fail build when a patch can't be applied (#797) --- prepare_vscode.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/prepare_vscode.sh b/prepare_vscode.sh index d3b35c8..b1e951b 100755 --- a/prepare_vscode.sh +++ b/prepare_vscode.sh @@ -11,7 +11,8 @@ cd vscode || exit for file in ../patches/*.patch; do if [ -f "$file" ]; then echo applying patch: $file; - if ! git apply --ignore-whitespace $file; then + git apply --ignore-whitespace "$file" + if [ $? -ne 0 ]; then echo failed to apply patch $file 1>&2 fi fi @@ -20,7 +21,8 @@ done for file in ../patches/user/*.patch; do if [ -f "$file" ]; then echo applying user patch: $file; - if ! git apply --ignore-whitespace $file; then + git apply --ignore-whitespace "$file" + if [ $? -ne 0 ]; then echo failed to apply patch $file 1>&2 fi fi