]> git.ozlabs.org Git - next-scripts/blob - merge_msg
split messag_helper out
[next-scripts] / merge_msg
1 #!/bin/bash
2
3 branch=""
4 [ "$1" = "-t" ] && {
5         branch="-t $2"
6         shift 2
7 }
8
9 file="$*"
10
11 gitk --merge -- $file &
12 [ "$file" ] && gvim $file
13
14 conf="a conflict"
15 [ "$#" -gt 1 ] && {
16         file=${file// /, }
17         file=$(echo $file | sed 's/,\([^,]*\)$/ and\1/')
18         conf="conflicts"
19 }
20
21 subject="manual merge of the BRANCH tree with the  tree"
22 body="Today's linux-next merge of the BRANCH tree got $conf in $file between commit  (%22%22) from the  tree and commit  (%22%22) from the BRANCH tree.%0A\
23 %0A\
24 I fixed it up (see below) and can carry the fix as necessary (no action%0A\
25 is required)."
26
27 $(dirname $0)/message_helper $branch "$subject" "$body"
28
29 exit 0