Re: "svn log" options and semantics
From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2003-10-25 01:12:30 CEST
C. Michael Pilato wrote:
Oh, I had forgotten about the XML output. It appears that this option was primarily intended to control the XML output, and suppressing the extra row of dashes is just a secondary nicety. (In the book there is an example about a page long of using "--incremental" to remove a row of dashes; that's over the top.)
Perhaps this mode (as applied to XML output) could be better described as "bare". After all, these blocks of XML are not "incremental" in the sense that you can append them to an existing "svn log --xml" document ... unless we provide "--xml-header" and "--xml-footer" functions to start and finish the document.
My reason for criticising this feature is that I think the word "incremental" better describes a mode which allows incremental revision (or date) ranges without overlap between the end of one range and the beginning of the next, as discussed below.
>>"svn log -rX:Y" prints the logs from the repository* revision at or
I don't know exactly what you mean. By "X+1" do you mean "+1 day" as your example seems to indicate, or "+1 revision number", or "+1 change of the item in question", or what? I can't see any way in which "-r{2003-09-20}:{today}" could be considered an "inclusive" equivalent of "-r{2003-09-21}:{yesterday}". They describe ranges that differ by a day at each end, and a day could contain any number of revisions or none.
> The problem, I think, is that our date-to-revision transformation
Yes, that sounds like part of a solution: to interpret a date as "First revision >= DATE" when it is the beginning of a range, but "Last revision < DATE" when it is the end of a range.
But that by itself is incompatible with the current "inclusive" model in which "svn log" describes the changes leading up to the revision that existed at the beginning of the range as well as changes that happened during the range. I think that it should describe only changes that happened _between_ the beginning and end of the range, just like "diff" does.
> In much the same way, sometimes you want "2003-08-20" to mean
Only when you want "inclusive" operation. I do not want this "inclusive" interpretation when operating in "incremental" mode, but it would be convenient at other times.
Urgh. Much of this difficulty in defining how it ought to work hinges on the definition of "revision". We never did clarify and spell out the difference between "revision" meaning a tree-state, and "revision" meaning a process of revising.
When I specify revisions with "-r", I think I am specifying tree states. However, the information provided by "svn log" is all about the process of revising, and therein lies the confusion. We have implemented "svn log -r33" as meaning "show the changes between tree-state 32 and tree-state 33". Why have we done that? Well, because we are confusing "tell me about the 33rd tree state" with "tell me about the 33rd process of revising".
The way I see it is: The canonical invocation of "log" is "log -r32:33" shows the changes between tree-state 32 and tree-state 33. "log -rN" can be defined as shorthand for "log -rN-1:N" if we like, but I'd like to regard that as a convenience that should not affect the design decisions.
Do I have any company in this line of thinking?
>>"svn log" crosses copy history by default; "--strict" disables this.
Yup, fine. "--ignore-copies", perhaps, as someone said.
>>How about "--ignore-ancestry"? That's based on my assumption that
OK.
- 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.