enum todo_command command;
struct commit *commit;
unsigned int flags;
- const char *arg;
int arg_len;
- size_t offset_in_buf;
+ /* The offset of the command and its argument in the strbuf */
+ size_t offset_in_buf, arg_offset;
};
struct todo_list {
int todo_list_parse_insn_buffer(struct repository *r, char *buf,
struct todo_list *todo_list);
+int todo_list_write_to_file(struct repository *r, struct todo_list *todo_list,
+ const char *file, const char *shortrevisions,
+ const char *shortonto, int num, unsigned flags);
void todo_list_release(struct todo_list *todo_list);
+const char *todo_item_get_arg(struct todo_list *todo_list,
+ struct todo_item *item);
/* Call this to setup defaults before parsing command line options */
void sequencer_init_config(struct replay_opts *opts);
* commits should be rebased onto the new base, this flag needs to be passed.
*/
#define TODO_LIST_REBASE_COUSINS (1U << 4)
-int sequencer_make_script(struct repository *repo, FILE *out,
- int argc, const char **argv,
+#define TODO_LIST_APPEND_TODO_HELP (1U << 5)
+
+int sequencer_make_script(struct repository *r, FILE *out, int argc,
+ const char **argv,
unsigned flags);
int sequencer_add_exec_commands(struct repository *r, const char *command);
-int transform_todos(struct repository *r, unsigned flags);
+int transform_todo_file(struct repository *r, unsigned flags);
enum missing_commit_check_level get_missing_commit_check_level(void);
int check_todo_list(struct repository *r);
int complete_action(struct repository *r, struct replay_opts *opts, unsigned flags,