[REVIEW] Chapter 9 : svn blame Command (Questions / Suggestions)
C. Michael Pilato
cmpilato at red-bean.com
Fri Jun 20 21:44:17 CDT 2008
Karl Heinz Marbaise wrote:
> Hi,
>
> I've got a little suggestion about the svn blame command.
>
> I have used blame sometimes and made the experience that it can be used
> to examine the information about how many lines have been changed by a
> particular person:
>
> svnsles9:/home/kama/testvc/book-trunk # svn blame button.c
> 4 kama int main (int argc, char **argv) {
> 5 kama printf("Test");
> 4 kama return 0;
> 4 kama }
> svnsles9:/home/kama/testvc/book-trunk # svn blame
> file:///home/kama/testvc/book/trunk/button.c -r 5:5
> - - int main (int argc, char **argv) {
> 5 kama printf("Test");
> - - return 0;
> - - }
> svnsles9:/home/kama/testvc/book-trunk # svn blame
> file:///home/kama/testvc/book/trunk/button.c -r 4:4
> 4 kama int main (int argc, char **argv) {
> 4 kama return 0;
> 4 kama }
> svnsles9:/home/kama/testvc/book-trunk #
>
> The first execution will give you an overview of which line is changed
> in which revision by whome..
> The second execution will give you detailed information which lines had
> been changed in a particular revision...
> The thirs will do the same...
>
> This can be used to create some kind of statistics....(like statsvn do)...
> May be it should be put some more information about the command into the
> book...only the blame in relationship with "-g" option is mentioned but
> the other opportunities are not mentioned (in particular the second
> execution)...may be they should be part of the reference section....
These are good ideas, but probably something we can defer until the next
version of the book.
> And now I have a question: Why is the line contents not part of the xml
> output as in the lines above ?
That's a good question. I don't know the answer. If I had to guess, I'd
say it was perhaps because there was no way to guarantee that the file
contents could be correctly converted to UTF-8 for proper inclusion in the
XML output stream.
--
C. Michael Pilato <cmpilato at red-bean.com> | http://cmpilato.blogspot.com/
"The Christian ideal has not been tried and found wanting. It has
been found difficult; and left untried." -- G. K. Chesterton
More information about the svnbook-dev
mailing list