Commit 9ac3be96 authored by ulan@chromium.org's avatar ulan@chromium.org

Wait for resolving conflicts in merge-to-branch script.

R=jkummerow@chromium.org

Review URL: https://chromiumcodereview.appspot.com/10939033

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12560 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 6f649aae
......@@ -180,10 +180,23 @@ the uploaded CL."
done
}
wait_for_resolving_conflicts() {
echo "Applying the patch failed. Either type \"ABORT<Return>\", or \
resolve the conflicts, stage the touched files with 'git add' and \
type \"RESOLVED<Return>\""
unset ANSWER
while [ "$ANSWER" != "RESOLVED" ] ; do
[[ "$ANSWER" == "ABORT" ]] && die "Applying the patch failed."
[[ -n "$ANSWER" ]] && echo "That was not 'RESOLVED' or 'ABORT'."
echo -n "> "
read ANSWER
done
}
# Takes a file containing the patch to apply as first argument.
apply_patch() {
patch $REVERSE_PATCH -p1 < "$1" > "$PATCH_OUTPUT_FILE" || \
{ cat "$PATCH_OUTPUT_FILE" && die "Applying the patch failed."; }
{ cat "$PATCH_OUTPUT_FILE" && wait_for_resolving_conflicts; }
tee < "$PATCH_OUTPUT_FILE" >(grep "patching file" \
| awk '{print $NF}' >> "$TOUCHED_FILES_FILE")
rm "$PATCH_OUTPUT_FILE"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment