Re: [PATCH 01/13] fast-import: add the 'done' command

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 28 Aug 2010, Sverre Rabbelier wrote:

> Currently the only way to end an import stream is to close it, which
> is not desirable when the stream that's being used is shared. For
> example, the remote helper infrastructure uses a pipe between it and
> the helper process, part of the protocol is to send a fast-import
> stream accross. Without a way to end the stream the remote helper
> infrastructure is forced to limit itself to have a command that uses
> a fast-import stream as it's last command.
> 
> Add a trivial 'done' command that causes fast-import to stop reading
> from the stream and exit.

Yeah, this is definitely worthwhile.

> ---
> 
>   Very straightforward. It is handled in parse_feature() instead of
>   in parse_one_feature() because I didn't want to allow '--done' as a
>   commandline argument. Allowing it would be silly, it surves no
>   other purpose than to indicate up front that the stream will
>   contain a 'done' command at the end.
> 
>   I'm fine too with dropping the feature and just adding the new
>   command, whichever is preferred.

I think the point of the feature would be to get the error response up 
front, where it might be easier to determine what to do about importers 
not supporting it. As such, I think the command line option actually makes 
at least as much sense, but it's probably not necessary anyway.

I believe there's a gfi mailing list, which ought to hear about this bit. 
Not that there are likely to be conflicts, but, when I was thinking about 
adding this command (for the same reason you're adding it), I'd called it 
"quit", so it's worth letting people know a de facto standard, so gfi 
implementations don't vary.

The code looks obviously good to me.

	-Daniel
*This .sig left intentionally blank*
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]