How do I have to extend the following logCommand, to get the --follow option of the git log command working?
Git git = new Git(myRepository);
Iterable<RevCommit> log = git.log().addPath("com/mycompany/myclass.java").call();
This option is implemented in jGit, but I don’t know how to use it. The logCommand’s methods don’t appear to be useful. Thank you!
During some midnight work I got the following:
The last commit of a LogCommand will get checked for renames against all older commits until a rename operation is found. This cycle will continue until no rename was found.
However, that search can take some time, especially if it iterates over all commits until the end and doesn’t find any rename operation anymore. So, I am open for any improvement. I guess git normally uses indexes to perform the follow option in shorter time.