mirror of
https://github.com/git/git.git
synced 2024-11-01 06:47:52 +01:00
572a7c52bb
The git-sh-setup script is already sourced in git-rebase.sh before calling into git-rebase--(am|interactive|merge).sh. There are no other callers of these scripts. It is therefore unnecessary to source git-sh-setup again in them. Signed-off-by: Junio C Hamano <gitster@pobox.com>
37 lines
918 B
Bash
37 lines
918 B
Bash
#!/bin/sh
|
|
#
|
|
# Copyright (c) 2010 Junio C Hamano.
|
|
#
|
|
|
|
case "$action" in
|
|
continue)
|
|
git am --resolved --resolvemsg="$resolvemsg" &&
|
|
move_to_original_branch
|
|
exit
|
|
;;
|
|
skip)
|
|
git am --skip --resolvemsg="$resolvemsg" &&
|
|
move_to_original_branch
|
|
exit
|
|
;;
|
|
esac
|
|
|
|
test -n "$rebase_root" && root_flag=--root
|
|
|
|
if test -n "$keep_empty"
|
|
then
|
|
# we have to do this the hard way. git format-patch completely squashes
|
|
# empty commits and even if it didn't the format doesn't really lend
|
|
# itself well to recording empty patches. fortunately, cherry-pick
|
|
# makes this easy
|
|
git cherry-pick --allow-empty "$revisions"
|
|
else
|
|
git format-patch -k --stdout --full-index --ignore-if-in-upstream \
|
|
--src-prefix=a/ --dst-prefix=b/ \
|
|
--no-renames $root_flag "$revisions" |
|
|
git am $git_am_opt --rebasing --resolvemsg="$resolvemsg"
|
|
fi && move_to_original_branch
|
|
|
|
ret=$?
|
|
test 0 != $ret -a -d "$state_dir" && write_basic_state
|
|
exit $ret
|