summaryrefslogtreecommitdiff
path: root/t/helper/test-tool.h
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2020-10-29 20:32:13 (GMT)
committerJunio C Hamano <gitster@pobox.com>2020-10-29 21:05:48 (GMT)
commitfe1a21d5267cae88d4312e3595909720717eb31c (patch)
treeaf631d211111b4497a9291e6e6e0af4d1d7c05d1 /t/helper/test-tool.h
parent47b1e890e3f7ba57e8c5bc364dcb04d8b2dc1c58 (diff)
downloadgit-fe1a21d5267cae88d4312e3595909720717eb31c.zip
git-fe1a21d5267cae88d4312e3595909720717eb31c.tar.gz
git-fe1a21d5267cae88d4312e3595909720717eb31c.tar.bz2
fast-rebase: demonstrate merge-ort's API via new test-tool command
Add a new test-tool command named 'fast-rebase', which is a super-slimmed down and nowhere near as capable version of 'git rebase'. 'test-tool fast-rebase' is not currently planned for usage in the testsuite, but is here for two purposes: 1) Demonstrate the desired API of merge-ort. In particular, fast-rebase takes advantage of the separation of the merging operation from the updating of the index and working tree, to allow it to pick N commits, but only update the index and working tree once at the end. Look for the calls to merge_incore_nonrecursive() and merge_switch_to_result(). 2) Provide a convenient benchmark that isn't polluted by the heavy disk writing and forking of unnecessary processes that comes from sequencer.c and merge-recursive.c. fast-rebase is not meant to replace sequencer.c, just give ideas on how sequencer.c can be changed. Updating sequencer.c with these goals is probably a large amount of work; writing a simple targeted command with no documentation, less-than-useful help messages, numerous limitations in terms of flags it can accept and situations it can handle, and which is flagged off from users is a much easier interim step. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/helper/test-tool.h')
-rw-r--r--t/helper/test-tool.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/t/helper/test-tool.h b/t/helper/test-tool.h
index 07034d3..fd0cafe 100644
--- a/t/helper/test-tool.h
+++ b/t/helper/test-tool.h
@@ -18,6 +18,7 @@ int cmd__dump_fsmonitor(int argc, const char **argv);
int cmd__dump_split_index(int argc, const char **argv);
int cmd__dump_untracked_cache(int argc, const char **argv);
int cmd__example_decorate(int argc, const char **argv);
+int cmd__fast_rebase(int argc, const char **argv);
int cmd__genrandom(int argc, const char **argv);
int cmd__genzeros(int argc, const char **argv);
int cmd__hashmap(int argc, const char **argv);