git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/2] tag: convert gpg_verify_tag to use struct object_id

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 13, 2017, 21:23 UTC
Message-ID
<xmqqvamwt4ju.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<CAGZ79kb3_K8NxpHuzAdHhSLWUcbw_X3qVVspPeuSNA4sAeT-Kw@mail.gmail.com>
Stefan Beller <sbeller@google.com> writes:
Show 32 quoted lines
> On Thu, Jul 13, 2017 at 1:52 PM, Junio C Hamano <gitster@pobox.com> wrote:
>> Stefan Beller <sbeller@google.com> writes:
>>
>>> diff --git a/builtin/verify-tag.c b/builtin/verify-tag.c
>>> index f9a5f7535a..ed8329340f 100644
>>> --- a/builtin/verify-tag.c
>>> +++ b/builtin/verify-tag.c
>>> @@ -56,20 +56,21 @@ int cmd_verify_tag(int argc, const char **argv, const char *prefix)
>>>       }
>>>
>>>       while (i < argc) {
>>> -             unsigned char sha1[20];
>>> +             struct object_id oid;
>>>               const char *name = argv[i++];
>>> -             if (get_sha1(name, sha1)) {
>>> +
>>> +             if (get_oid(name, &oid)) {
>>>                       had_error = !!error("tag '%s' not found.", name);
>>>                       continue;
>>>               }
>>
>> This part is already done, it seems, in bc/object-id topic, even
>> though other parts are not yet done?
>
> Oops. I assumed the latest bc/object-id would have been in master
> already, but after checking it is not. 967635dc3c2
> (builtin/verify-tag: convert to struct object_id)
> converts this part, although there are 2 differences:
> * I added a stray newline before get_oid
> * The argument to gpg_verify_tag is a sha1 or oid
>
> So yes, this produces a merge conflict. :/

That is OK. This actually shouldn't create any meaningful conflict. Both try to do the same code, with only a blank-line difference.

As Brian said bc/object-id would be rerolled, I was wondering if I should queue these two patches (even though I already queued them) myself, or it would be better for you to send them to Brian to make it part of his series.

Previous: Stefan BellerNext: Stefan Beller
Message 6 of 10 in “commit: convert lookup_commit_graft to struct object_id”
  1. 1/2 commit: convert lookup_commit_graft to struct object_idStefan Beller, Jul 13, 2017
  2. 2/2 tag: convert gpg_verify_tag to use struct object_idStefan Beller, Jul 13, 2017
  3. Junio C HamanoJul 13, 2017
  4. Junio C HamanoJul 13, 2017
  5. Stefan BellerJul 13, 2017
  6. Junio C HamanoJul 13, 2017
  7. Stefan BellerJul 13, 2017
  8. brian m. carlsonJul 13, 2017
  9. brian m. carlsonJul 13, 2017
  10. Junio C HamanoJul 13, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.