Thread (185 messages) 185 messages, 9 authors, 2022-12-15

Re: [PATCH v6 08/13] merge-recursive: move better_branch_name() to merge.c

From: Derrick Stolee <hidden>
Date: 2021-01-05 16:20:20

On 11/24/2020 6:53 AM, Alban Gruin wrote:
better_branch_name() will be used by merge-octopus once it is rewritten
in C, so instead of duplicating it, this moves this function
preventively inside an appropriate file in libgit.a.  This function is
also renamed to reflect its usage by merge strategies.
s/preventively/preemptively/
quoted hunk ↗ jump to hunk
diff --git a/cache.h b/cache.h
index be16ab3215..2d844576ea 100644
--- a/cache.h
+++ b/cache.h
@@ -1933,7 +1933,7 @@ int checkout_fast_forward(struct repository *r,
 			  const struct object_id *from,
 			  const struct object_id *to,
 			  int overwrite_ignore);
-
+char *merge_get_better_branch_name(const char *branch);
 
 int sane_execvp(const char *file, char *const argv[]);
I tend to avoid adding new things to the enormous cache.h, but the
best place I could see was refs.h next to repo_default_branch_name().

Maybe cache.h is fine.

-Stolee
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help