mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-21 18:03:54 +00:00
describe: rename _object() to _commit()
We don't describe arbitrary object, so let's give it the name of the one object type we accept.
This commit is contained in:
parent
af6cc38fc0
commit
1f501a086b
@ -55,7 +55,7 @@ typedef struct git_describe_opts {
|
||||
GIT_DESCRIBE_DEFAULT_MAX_CANDIDATES_TAGS, \
|
||||
GIT_DESCRIBE_DEFAULT_ABBREVIATED_SIZE}
|
||||
|
||||
GIT_EXTERN(int) git_describe_object(
|
||||
GIT_EXTERN(int) git_describe_commit(
|
||||
git_buf *out,
|
||||
git_object *committish,
|
||||
git_describe_opts *opts);
|
||||
|
@ -626,7 +626,7 @@ static int normalize_options(
|
||||
|
||||
/** TODO: Add git_object_describe_workdir(git_buf *, const char *dirty_suffix, git_describe_opts *); */
|
||||
|
||||
int git_describe_object(
|
||||
int git_describe_commit(
|
||||
git_buf *out,
|
||||
git_object *committish,
|
||||
git_describe_opts *opts)
|
||||
|
@ -39,7 +39,7 @@ void test_describe_describe__cannot_describe_against_a_repo_with_no_ref(void)
|
||||
|
||||
cl_git_pass(git_reference_foreach(repo, delete_cb, NULL));
|
||||
|
||||
cl_git_fail(git_describe_object(&buf, object, &opts));
|
||||
cl_git_fail(git_describe_commit(&buf, object, &opts));
|
||||
|
||||
git_object_free(object);
|
||||
git_buf_free(&buf);
|
||||
|
@ -12,7 +12,7 @@ void assert_describe(
|
||||
|
||||
cl_git_pass(git_revparse_single(&object, repo, revparse_spec));
|
||||
|
||||
cl_git_pass(git_describe_object(&label, object, opts));
|
||||
cl_git_pass(git_describe_commit(&label, object, opts));
|
||||
|
||||
if (is_prefix_match)
|
||||
cl_assert_equal_i(0, git__prefixcmp(git_buf_cstr(&label), expected_output));
|
||||
|
Loading…
Reference in New Issue
Block a user