Hello All
I was trying to implement svn blame with svnkit and Its working the problem is that the log file is not the needed one, I need to extract for each source line in the project in the svn the person how modified it.
here is the code :
Iterator<SVNURL> fileiter = entries.iterator();
while (fileiter.hasNext()) {
SVNURL svnfileUrl = (SVNURL) fileiter.next();
svnLogClient.doAnnotate(svnfileUrl, SVNRevision.HEAD,
SVNRevision.create(1), SVNRevision.HEAD,
new ISVNAnnotateHandler() {
public void handleLine(Date date, long revision,
String author, String line)
throws SVNException {
svnBlameExtractor.addLineNo(line);
svnBlameExtractor
.setVcsNameOfProgrammerToBlame(author);
svnBlameExtractor.setDate(date);
svnBlameExtractor.setRevision(revision);
}
});
svnBlameExtractor.generateReport();
And here is a sample of code :
-----------------------------------------------------------------------
Revision :1246
-----------------------------------------------------------------------
Author :apit
Modification :
------------------------------------------------------------------------
package com.piterion.test;
public class Class1 {
Cla
}
package com.piterion.test2;
public class Class2 {
s
}
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="output" path="bin"/>
</classpath>
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>com.piterion.test</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
We need that that report looks like
Auther : apit
Modifications :
Class1 line 2
Class2 line 4
......
is it possible and how to do it ?