diff options
author | Alban Gruin <alban.gruin@gmail.com> | 2018-08-28 15:10:40 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-08-29 23:38:18 +0300 |
commit | 65850686cf072d6de88880247adb7113db8a52f2 (patch) | |
tree | 5fbea0be6ec16fe712d62503ed6a885b804bc9c8 /sequencer.h | |
parent | f22e4e1a3c2faaac59099aaca15641c18f478f77 (diff) |
rebase -i: rewrite write_basic_state() in C
This rewrites write_basic_state() from git-rebase.sh in C. This is the
first step in the conversion of init_basic_state(), hence the mode in
rebase--helper.c is called INIT_BASIC_STATE. init_basic_state() will be
converted in the next commit.
The part of read_strategy_opts() that parses the stategy options is
moved to a new function to allow its use in rebase--helper.c.
Finally, the call to write_basic_state() is removed from
git-rebase--interactive.sh, replaced by a call to `--init-basic-state`.
Signed-off-by: Alban Gruin <alban.gruin@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'sequencer.h')
-rw-r--r-- | sequencer.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sequencer.h b/sequencer.h index 02e3d7940e..aab280f276 100644 --- a/sequencer.h +++ b/sequencer.h @@ -119,3 +119,7 @@ int prepare_branch_to_be_rebased(struct replay_opts *opts, const char *commit); void print_commit_summary(const char *prefix, const struct object_id *oid, unsigned int flags); #endif + +void parse_strategy_opts(struct replay_opts *opts, char *raw_opts); +int write_basic_state(struct replay_opts *opts, const char *head_name, + const char *onto, const char *orig_head); |