[darcs-users] darcs patch: Add Patch-salt as ignored prefix

David Roundy droundy at darcs.net
Wed Oct 8 18:08:41 UTC 2008


On Wed, Oct 08, 2008 at 10:53:34AM -0600, zooko wrote:
> following-up to my own note:
>
> On Oct 8, 2008, at 10:42 AM, zooko wrote:
>
>> See what I mean?  That's the key concept of "out-of-band
>> signalling".  Make it so that the metadata which darcs adds and which
>> darcs parses and hides and uses is completely separate from the patch
>> comment that the user edits, and make it so the two cannot be
>> confused with one another.
>
> Basically, what I would *really* like is if darcs had a way to put  
> arbitrary key-value pairs into the patch description such that old  
> versions of darcs would ignore key-value pairs whose keys they didn't  
> recognize.
>
> Then, we could put "patch-salt" as a key and the salt as a value, it  
> would be completely separate from the patch comment (as it should be), 
> and old versions of darcs would simply ignore it.
>
> However, old versions of darcs don't do that.  If you put a new field  
> into their patch metadata then they croak with an error.  Therefore, the 
> only place where we can stick the patch salt is into the only  
> arbitrary-length field in the darcs metadata, which happens to be the  
> patch comment.
>
> However, our goal should be basically to redefine the patch comment so 
> that in the future there are two separate chunks of data in the patch 
> comments: the user-editable, user-visible part which serves the same 
> purpose that the patch comment has always served, and the arbitrary 
> key-value-pairs part which serves as a place where future versions of 
> darcs can exchange new fields with each other without hopelessly 
> confusing darcs 2.1.0 when it sees patches containing those new fields.
>
> Make sense?

But why? That's what you haven't explained.  Why not just hide some
data that we don't use and allow users to hide some data if they would
like to?

David


More information about the darcs-users mailing list