Re: [PATCH v5 12/40] t0400: add 'put_raw_obj' instruction to odb-helper script
- From
Christian Couder <christian.couder@gmail.com>
- Date
- Sep 14, 2017, 07:09 UTC
- Message-ID
- <CAP8UFD04cNASyWGURb7wYMX2eyOqKAumVuFvHCQ-nWYoPzzJZw@mail.gmail.com>
- In-Reply-To
- <50C9AF15-26DF-48F5-926E-B5D57F492DD1@gmail.com>
On Sun, Sep 10, 2017 at 2:12 PM, Lars Schneider <larsxschneider@gmail.com> wrote:
Show 11 quoted lines
> >> On 03 Aug 2017, at 10:18, Christian Couder <christian.couder@gmail.com> wrote: >> >> To properly test passing objects from Git to an external odb >> we need an odb-helper script that supports a 'put' >> capability/instruction. >> >> For now we will support only sending raw blobs, so the >> supported capability/instruction will be 'put_raw_obj'. > > What other kind of blobs do you imagine could we send?
As for the get instructions there could be 'put_git_obj' to send blobs in the Git format and 'put_direct' to have the helper read directly from the Git object store.
Show 8 quoted lines
>> +put_raw_obj) >> + sha1="$2" >> + size="$3" >> + kind="$4" >> + writen=$(git hash-object -w -t "$kind" --stdin) >> + test "$writen" = "$sha1" || die "bad sha1 passed '$sha1' vs writen '$writen'" > > Typo? Should it be "written"?
Yeah, thanks. It's fixed in the current version.