Re: [VOTE] merge the log-message-templates branch to trunk
From: Julian Foad <julianfoad_at_btopenworld.com>
Date: Mon, 15 Sep 2014 15:43:34 +0100
Hi Brane.
Isn't this fun, brainstorming a new feature (re)design?
Your proposal contains good points about adding a format number and a comment syntax as well as an extensible command syntax.
Branko Čibej wrote:
You snipped the bit after the examples, where I stated what my proposal actually was, thus giving the impression that you thought my proposal was to define minimal syntax(es) looking like '$foo' and '${foo bar}' specifically.
> Allow me to very strongly disagree with this idea. :) For a simple
Allow me to observe that your proposal for reserving '^#!.*$' as the syntax for new directives is one specific implementation of my actual suggestion.
I didn't mention it at the time, but a minimal syntax where the extent can be recognized (such as '${.*}' or '^#!.*$') has advantages over one where the extent cannot be recognized (such as merely '$.*').
> Here's what I think is missing from the template implementation. We
And:
* An escape syntax to enable specifying log template text which (when shown to the user) must contain a character sequence reserved for template mark-up, such as a line starting with '#' or with '--'.
> Once we have these elements, the template format becomes arbitrarily
Largely sounds good.
For the escaping I'd suggest:
* Three backslash escapes are recognized everywhere in the literal text:
The use of formatting directives on separate lines is, in principle, enough to support any future extensions. In practice, however, for convenience we may very well want to introduce substitution fields within a line, and a way to attach a user-visible comment to a specific field within a line, and such like. The 'format' mechanism gives us the upgrade path whereby we can do this. For example, a new format might introduce ${...} as a substitution syntax framework (and '\$' as a new escape producing a literal '$'). The 'plain text' parts would no longer be plain text, and so we must define how a client will process a format that is too new for that client.
An example template illustrating the use of different formats:
[[[
I would propose these versioning rules:
* A template can contain multiple sections, each of a different format.
* A client SHOULD support the current format "1.x" and also at least the
* A client uses exactly one section, which is the section with the
- Julian
|
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.