Mercurial > hg
comparison hgmerge @ 1797:42f75cd04bf4
Fix hgmerge: mkdir "'/tmp'/hgmerge..." and ask_if_merged() didn't work.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Thu, 23 Feb 2006 14:42:47 +0100 |
parents | ac7b91bcbd8d |
children | d610fe0e6893 |
comparison
equal
deleted
inserted
replaced
1796:a373881fdf2a | 1797:42f75cd04bf4 |
---|---|
43 | 43 |
44 # random part of names | 44 # random part of names |
45 RAND="$RANDOM$RANDOM" | 45 RAND="$RANDOM$RANDOM" |
46 | 46 |
47 # temporary directory for diff+patch merge | 47 # temporary directory for diff+patch merge |
48 HGTMP="${TMPDIR-'/tmp'}/hgmerge.$RAND" | 48 HGTMP="${TMPDIR-/tmp}/hgmerge.$RAND" |
49 | 49 |
50 # backup file | 50 # backup file |
51 BACKUP="$LOCAL.orig.$RAND" | 51 BACKUP="$LOCAL.orig.$RAND" |
52 | 52 |
53 # file used to test for file change | 53 # file used to test for file change |
72 exit 1 | 72 exit 1 |
73 } | 73 } |
74 | 74 |
75 # Ask if the merge was successful | 75 # Ask if the merge was successful |
76 ask_if_merged() { | 76 ask_if_merged() { |
77 while 1; do | 77 while true; do |
78 echo "$LOCAL seems unchanged. Was the merge successful? [y/n]" | 78 echo "$LOCAL seems unchanged." |
79 echo "Was the merge successful? [y/n]" | |
79 read answer | 80 read answer |
80 case answer in | 81 case "$answer" in |
81 y*|Y*) success;; | 82 y*|Y*) success;; |
82 n*|N*) failure;; | 83 n*|N*) failure;; |
83 esac | 84 esac |
84 done | 85 done |
85 } | 86 } |