vendor/libgit2/include/git2/merge.h in rugged-0.27.10.1 vs vendor/libgit2/include/git2/merge.h in rugged-0.28.0

- old
+ new

@@ -201,16 +201,17 @@ #define GIT_MERGE_FILE_OPTIONS_VERSION 1 #define GIT_MERGE_FILE_OPTIONS_INIT {GIT_MERGE_FILE_OPTIONS_VERSION} /** + * Initialize git_merge_file_options structure + * * Initializes a `git_merge_file_options` with default values. Equivalent to - * creating an instance with GIT_MERGE_FILE_OPTIONS_INIT. + * creating an instance with `GIT_MERGE_FILE_OPTIONS_INIT`. * - * @param opts the `git_merge_file_options` instance to initialize. - * @param version the version of the struct; you should pass - * `GIT_MERGE_FILE_OPTIONS_VERSION` here. + * @param opts The `git_merge_file_options` struct to initialize. + * @param version The struct version; pass `GIT_MERGE_FILE_OPTIONS_VERSION`. * @return Zero on success; -1 on failure. */ GIT_EXTERN(int) git_merge_file_init_options( git_merge_file_options *opts, unsigned int version); @@ -298,16 +299,17 @@ #define GIT_MERGE_OPTIONS_VERSION 1 #define GIT_MERGE_OPTIONS_INIT { \ GIT_MERGE_OPTIONS_VERSION, GIT_MERGE_FIND_RENAMES } /** + * Initialize git_merge_options structure + * * Initializes a `git_merge_options` with default values. Equivalent to - * creating an instance with GIT_MERGE_OPTIONS_INIT. + * creating an instance with `GIT_MERGE_OPTIONS_INIT`. * - * @param opts the `git_merge_options` instance to initialize. - * @param version the version of the struct; you should pass - * `GIT_MERGE_OPTIONS_VERSION` here. + * @param opts The `git_merge_options` struct to initialize. + * @param version The struct version; pass `GIT_MERGE_OPTIONS_VERSION`. * @return Zero on success; -1 on failure. */ GIT_EXTERN(int) git_merge_init_options( git_merge_options *opts, unsigned int version); @@ -381,9 +383,28 @@ */ GIT_EXTERN(int) git_merge_analysis( git_merge_analysis_t *analysis_out, git_merge_preference_t *preference_out, git_repository *repo, + const git_annotated_commit **their_heads, + size_t their_heads_len); + +/** + * Analyzes the given branch(es) and determines the opportunities for + * merging them into a reference. + * + * @param analysis_out analysis enumeration that the result is written into + * @param repo the repository to merge + * @param our_ref the reference to perform the analysis from + * @param their_heads the heads to merge into + * @param their_heads_len the number of heads to merge + * @return 0 on success or error code + */ +GIT_EXTERN(int) git_merge_analysis_for_ref( + git_merge_analysis_t *analysis_out, + git_merge_preference_t *preference_out, + git_repository *repo, + git_reference *our_ref, const git_annotated_commit **their_heads, size_t their_heads_len); /** * Find a merge base between two commits