Merge branch 'mh/notes-string-list'
[git/mjg.git] / mergetools / p4merge
blob295361a8aa7d075bbb9fdb8173858e37f9a43211
1 diff_cmd () {
2         # p4merge does not like /dev/null
3         rm_local=
4         rm_remote=
5         if test "/dev/null" = "$LOCAL"
6         then
7                 LOCAL="./p4merge-dev-null.LOCAL.$$"
8                 >"$LOCAL"
9                 rm_local=true
10         fi
11         if test "/dev/null" = "$REMOTE"
12         then
13                 REMOTE="./p4merge-dev-null.REMOTE.$$"
14                 >"$REMOTE"
15                 rm_remote=true
16         fi
18         "$merge_tool_path" "$LOCAL" "$REMOTE"
20         if test -n "$rm_local"
21         then
22                 rm -f "$LOCAL"
23         fi
24         if test -n "$rm_remote"
25         then
26                 rm -f "$REMOTE"
27         fi
30 merge_cmd () {
31         touch "$BACKUP"
32         $base_present || >"$BASE"
33         "$merge_tool_path" "$BASE" "$LOCAL" "$REMOTE" "$MERGED"
34         check_unchanged