[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Issue #2219: Canonicalize values in svn:keywords

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2005-04-08 17:35:47 CEST

John Peacock wrote:
>> svn propset svn:keywords 'Author Date Revision MyCustomKeyword="%D
>> %U"' foo
[...]
> patch that Madan submitted would still be completely transparent to that
> notation. The only thing the proposed patch does is fix the known
> keywords (I hate to keep repeating that); unknown values are copied
> unaltered, so we are free to extend the notation however seems fit.

Careful. The patch would be completely transparent to that particular example
of a string, but not necessarily to that notation, depending on how that
notation is defined (and the notation isn't defined in this example). For
example, it would reduce multiple spaces to a single space, and would destroy
any occurrence of " Date " etc. that might appear inside the
MyCustomKeyword="%D %U" sub-string, because it doesn't recognise that that is a
quoted sub-string.

   'Author Date Revision MyCustomKeyword="The date is %D. The author is %A"'
=>
   'Author Date Revision MyCustomKeyword="The is %D. The is %A"'

Now, I'm not saying that the patch isn't good enough, just that it still
restricts syntax extensions in certain ways.

I would favour having this canonicalization and accepting that the
"svn:keywords" string will always only consist of simple keywords or strings
without embedded spaces at all. (If we need some stronger syntax in future,
there are other solutions - e.g. it could live in a different property such as
"svn:user-keywords".)

So, I think I'm happy with the concept of the current patch that passes through
unrecognised "words". I haven't reviewed the code yet.

- Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Apr 8 17:37:10 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.