Skip to content

Commit

Permalink
pm_patch.env: patch -r /dev/null --no-backup-if-mismatch by default
Browse files Browse the repository at this point in the history
Signed-off-by: Roberto A. Foglietta <roberto.foglietta@gmail.com>
  • Loading branch information
robang74 committed Jul 2, 2023
1 parent cb75d7d commit 21f3e66
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/tools/pm_patch.env
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ fi
pm_patch(){
log "pm_patch $@"
$PATCH_EXEC "$@" --ignore-whitespace --remove-empty-files -F 3 -p 1 \
--unified --force -d "$ROOT_DIR" --quiet -i "$PATCH_FILE" 2>&1 | \
tee -a "$PM_LOG_FILE"
--unified --force -d "$ROOT_DIR" --quiet -i "$PATCH_FILE" 2>&1 \
-r /dev/null --no-backup-if-mismatch | tee -a "$PM_LOG_FILE"
[ $? -eq 0 ] && log "returns OK"
}

Expand All @@ -127,7 +127,7 @@ remove_text_patch() {
log "Revert patch"
logbar
log
pm_patch -R --no-backup-if-mismatch || failure
pm_patch -R || failure
# RAF, BUG FIX: here below the logic of the original code which exits when
# succed but inhibiting the back-up of the applied patch
# pm_patch -R --no-backup-if-mismatch && success
Expand Down Expand Up @@ -233,7 +233,7 @@ install_text_patch() {
log "Apply patch"
logbar
log
pm_patch --no-backup-if-mismatch || failure
pm_patch || failure
# RAF, BUG FIX: here below the logic of the original code which exits when
# succed but inhibiting the back-up of the applied patch
# Morover, it is sane to exit in case of failure to avoid the
Expand Down

0 comments on commit 21f3e66

Please sign in to comment.