summaryrefslogtreecommitdiff
path: root/merge-recursive.h
diff options
context:
space:
mode:
Diffstat (limited to 'merge-recursive.h')
-rw-r--r--merge-recursive.h19
1 files changed, 12 insertions, 7 deletions
diff --git a/merge-recursive.h b/merge-recursive.h
index 978847e..e67d38c 100644
--- a/merge-recursive.h
+++ b/merge-recursive.h
@@ -31,6 +31,7 @@ struct merge_options {
/* xdiff-related options (patience, ignore whitespace, ours/theirs) */
long xdl_opts;
+ int conflict_style;
enum {
MERGE_VARIANT_NORMAL = 0,
MERGE_VARIANT_OURS,
@@ -46,6 +47,8 @@ struct merge_options {
/* miscellaneous control options */
const char *subtree_shift;
unsigned renormalize : 1;
+ unsigned record_conflict_msgs_as_headers : 1;
+ const char *msg_header_prefix;
/* internal fields used by the implementation */
struct merge_options_internal *priv;
@@ -53,6 +56,9 @@ struct merge_options {
void init_merge_options(struct merge_options *opt, struct repository *repo);
+void copy_merge_options(struct merge_options *dst, struct merge_options *src);
+void clear_merge_options(struct merge_options *opt);
+
/* parse the option in s and update the relevant field of opt */
int parse_merge_opt(struct merge_options *opt, const char *s);
@@ -69,9 +75,8 @@ int parse_merge_opt(struct merge_options *opt, const char *s);
*
* Outputs:
* - See RETURN VALUES above
- * - No commit is created
* - opt->repo->index has the new index
- * - $GIT_INDEX_FILE is not updated
+ * - new index NOT written to disk
* - The working tree is updated with results of the merge
*/
int merge_trees(struct merge_options *opt,
@@ -81,7 +86,7 @@ int merge_trees(struct merge_options *opt,
/*
* merge_recursive is like merge_trees() but with recursive ancestor
- * consolidation and, if the commit is clean, creation of a commit.
+ * consolidation.
*
* NOTE: empirically, about a decade ago it was determined that with more
* than two merge bases, optimal behavior was found when the
@@ -91,9 +96,9 @@ int merge_trees(struct merge_options *opt,
*
* Outputs:
* - See RETURN VALUES above
- * - If merge is clean, a commit is created and its address written to *result
+ * - *result is treated as scratch space for temporary recursive merges
* - opt->repo->index has the new index
- * - $GIT_INDEX_FILE is not updated
+ * - new index NOT written to disk
* - The working tree is updated with results of the merge
*/
int merge_recursive(struct merge_options *opt,
@@ -109,9 +114,9 @@ int merge_recursive(struct merge_options *opt,
*
* Outputs:
* - See RETURN VALUES above
- * - If merge is clean, a commit is created and its address written to *result
+ * - *result is treated as scratch space for temporary recursive merges
* - opt->repo->index has the new index
- * - $GIT_INDEX_FILE is updated
+ * - new index also written to $GIT_INDEX_FILE on disk
* - The working tree is updated with results of the merge
*/
int merge_recursive_generic(struct merge_options *opt,