Re: [PATCH 6/9] git-hash-object: Add --stdin-paths option
- From
Brian Downing <bdowning@lavos.net>
- Date
- Oct 26, 2007, 23:19 UTC
- Message-ID
- <20071026231902.GC2519@lavos.net>
- In-Reply-To
- <7vy7dpwpz4.fsf@gitster.siamese.dyndns.org>
On Fri, Oct 26, 2007 at 02:00:47PM -0700, Junio C Hamano wrote:
Show 8 quoted lines
> In addition, if you are enhancing cat-file to spew chunked > output out, I suspect that there should be a mode of operation > for hash-object that eats that data format. IOW, this pipe > > git-cat-file --batch <list-of-sha1 | > git-hash-object --batch > > should be an intuitive no-op, shouldn't it?
I think that's an obviously good thing to do. However, given your suggested output format (which I also like):
Show 7 quoted lines
> * git-cat-file --batch <list-of-sha1 > > outputs a record of this form > > <sha1> SP <type> SP <size> LF <contents> LF > > for each of the input lines.
What should the input behavior be? Obviously the sha1 will probably not be known on the input side. Should that simply be optional (i.e. it will accept either "<sha1> SP <type> SP <size>" or "<type> SP <size>" or should it only accept the latter, and a dummy sha1 will need to be filled in if the sha1 is not known (presumably "000...000")?
-bcd