If rejects are empty after using the editor, merge with diff+patch was ok.
authorThomas Arendsen Hein <thomas@intevation.de>
Thu, 04 Aug 2005 17:23:31 +0100
changeset 830 ca080d28d0af
parent 829 764b0350acb8
child 831 232d0616a80a
If rejects are empty after using the editor, merge with diff+patch was ok.
hgmerge
--- a/hgmerge
+++ b/hgmerge
@@ -75,7 +75,8 @@ if type diff > /dev/null 2>&1 && type pa
     if patch "$LOCAL" < "$HGTMP/diff"; then
 	cleanup_exit 0
     else
-	$EDITOR "$LOCAL" "$LOCAL.rej"
+	# If rejects are empty after using the editor, merge was ok
+	$EDITOR "$LOCAL" "$LOCAL.rej" && test -s "$LOCAL.rej" || cleanup_exit 0
     fi
     cleanup_exit 1
 fi