Commit 1f501a08 by Carlos Martín Nieto

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.
parent af6cc38f
......@@ -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));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment