]> git.ipfire.org Git - thirdparty/git.git/commitdiff
sequencer: restrict scope of a formerly public function
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Tue, 7 Sep 2021 21:05:12 +0000 (21:05 +0000)
committerJunio C Hamano <gitster@pobox.com>
Wed, 8 Sep 2021 04:45:33 +0000 (21:45 -0700)
The function to add the `exec` commands to the todo list only needed to
be public API because it was not only used internally by the sequencer,
but also by `git rebase --preserve-merges`.

Now that that mode has been removed, we no longer need that function to
be scoped publicly.

Helped-by: Alban Gruin <alban.gruin@gmail.com>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Reviewed-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
sequencer.c
sequencer.h

index 7f07cd00f3f20ab3dc0c508653ac28bdd8e8b8c1..3cdb20b07432b4dcb9640c12ab72866fef83a166 100644 (file)
@@ -5387,8 +5387,8 @@ int sequencer_make_script(struct repository *r, struct strbuf *out, int argc,
  * Add commands after pick and (series of) squash/fixup commands
  * in the todo list.
  */
-void todo_list_add_exec_commands(struct todo_list *todo_list,
-                                struct string_list *commands)
+static void todo_list_add_exec_commands(struct todo_list *todo_list,
+                                       struct string_list *commands)
 {
        struct strbuf *buf = &todo_list->buf;
        size_t base_offset = buf->len;
index d57d8ea23d7a225e10788859cab4bebf5cfc1346..60a156ea906273b2bf7ba5a833a55e68dc2dafa2 100644 (file)
@@ -160,8 +160,6 @@ int sequencer_remove_state(struct replay_opts *opts);
 int sequencer_make_script(struct repository *r, struct strbuf *out, int argc,
                          const char **argv, unsigned flags);
 
-void todo_list_add_exec_commands(struct todo_list *todo_list,
-                                struct string_list *commands);
 int complete_action(struct repository *r, struct replay_opts *opts, unsigned flags,
                    const char *shortrevisions, const char *onto_name,
                    struct commit *onto, const struct object_id *orig_head,