path: root/sequencer.h
diff options
authorAlban Gruin <>2019-03-05 19:17:57 (GMT)
committerJunio C Hamano <>2019-03-07 00:17:57 (GMT)
commit94bcad797966b6a3490bc6806d3ee3eed54da9d9 (patch)
tree48cf20490b699fe3d266eb1da84c24f125245f72 /sequencer.h
parentd358fc286d1da690fb4acea629457faa9010944a (diff)
sequencer: change complete_action() to use the refactored functions
complete_action() used functions that read the todo-list file, made some changes to it, and wrote it back to the disk. The previous commits were dedicated to separate the part that deals with the file from the actual logic of these functions. Now that this is done, we can call directly the "logic" functions to avoid useless file access. The parsing of the list has to be done by the caller. If the buffer of the todo list provided by the caller is empty, a `noop' command is directly added to the todo list, without touching the buffer. Signed-off-by: Alban Gruin <> Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'sequencer.h')
1 files changed, 1 insertions, 1 deletions
diff --git a/sequencer.h b/sequencer.h
index e25f515..7029b39 100644
--- a/sequencer.h
+++ b/sequencer.h
@@ -152,7 +152,7 @@ int check_todo_list_from_file(struct repository *r);
int complete_action(struct repository *r, struct replay_opts *opts, unsigned flags,
const char *shortrevisions, const char *onto_name,
const char *onto, const char *orig_head, struct string_list *commands,
- unsigned autosquash);
+ unsigned autosquash, struct todo_list *todo_list);
int rearrange_squash_in_todo_file(struct repository *r);
extern const char sign_off_header[];