diff options
author | Jonathan Nieder <jrnieder@gmail.com> | 2011-08-13 12:06:23 -0500 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-12-12 13:32:16 -0800 |
commit | 7f13334e074bb053eccd14787e416306bc4b413a (patch) | |
tree | 94de9095639d371cbbdb8862e13b848703e1174e /t | |
parent | revert: allow cherry-pick --continue to commit before resuming (diff) | |
download | tgif-7f13334e074bb053eccd14787e416306bc4b413a.tar.xz |
revert: pass around rev-list args in already-parsed form
Since 7e2bfd3f (revert: allow cherry-picking more than one commit,
2010-07-02), the pick/revert machinery has kept track of the set of
commits to be cherry-picked or reverted using commit_argc and
commit_argv variables, storing the corresponding command-line
parameters.
Future callers as other commands are built in (am, rebase, sequencer)
may find it easier to pass rev-list options to this machinery in
already-parsed form. Teach cmd_cherry_pick and cmd_revert to parse
the rev-list arguments in advance and pass the commit set to
pick_revisions() as a rev_info structure.
Original patch by Jonathan, tweaks and test from Ram.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Improved-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-x | t/t3510-cherry-pick-sequence.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/t/t3510-cherry-pick-sequence.sh b/t/t3510-cherry-pick-sequence.sh index 4d1883b734..56c95ec18c 100755 --- a/t/t3510-cherry-pick-sequence.sh +++ b/t/t3510-cherry-pick-sequence.sh @@ -461,4 +461,9 @@ test_expect_success 'malformed instruction sheet 2' ' test_must_fail git cherry-pick --continue ' +test_expect_success 'empty commit set' ' + pristine_detach initial && + test_expect_code 128 git cherry-pick base..base +' + test_done |