Merge branch 'km/config-grammofix' into maint
[gitweb.git] / mergetools / p4merge
index 8a36916567a234c354af9994df9c28788749e7fa..7a5b291dd28ad5b60ca0492480b800aaa9cc929e 100644 (file)
@@ -20,10 +20,12 @@ diff_cmd () {
 }
 
 merge_cmd () {
-       touch "$BACKUP"
-       $base_present || >"$BASE"
-       "$merge_tool_path" "$BASE" "$LOCAL" "$REMOTE" "$MERGED"
-       check_unchanged
+       if ! $base_present
+       then
+               cp -- "$LOCAL" "$BASE"
+               create_virtual_base "$BASE" "$REMOTE"
+       fi
+       "$merge_tool_path" "$BASE" "$REMOTE" "$LOCAL" "$MERGED"
 }
 
 create_empty_file () {