]> source.dussan.org Git - jgit.git/commit
Added file path similarity to scoring metric in rename detection 93/1093/3
authorJeff Schumacher <jeffschu@google.com>
Fri, 9 Jul 2010 22:11:54 +0000 (15:11 -0700)
committerJeff Schumacher <jeffschu@google.com>
Mon, 12 Jul 2010 19:52:05 +0000 (12:52 -0700)
commit9a48de86d892a3a1f028f4899f34898e58d759b3
tree680ed79384aadf9137600171b9dd2eed6e2fb395
parent4c14b7869d47a28aca29e219a3bae10f43083b33
Added file path similarity to scoring metric in rename detection

The scoring method was not taking into account the similarity of
the file paths and file names. I changed the metric so that it is 99%
based on content (which used to be 100% of the old metric), and 1%
based on path similarity. Of that 1%, half (.5% of the total final
score) is based on the actual file names (e.g. "foo.java"), and half
on the directory (e.g. "src/com/foo/bar/").

Change-Id: I94f0c23bf6413c491b10d5625f6ad7d2ecfb4def
org.eclipse.jgit.test/tst/org/eclipse/jgit/diff/RenameDetectorTest.java
org.eclipse.jgit.test/tst/org/eclipse/jgit/diff/SimilarityIndexTest.java
org.eclipse.jgit/src/org/eclipse/jgit/diff/SimilarityIndex.java
org.eclipse.jgit/src/org/eclipse/jgit/diff/SimilarityRenameDetector.java