Skip to content

Commit fd1de81

Browse files
committed
add comment on why -f is used
1 parent 9c18d78 commit fd1de81

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/org/opensolaris/opengrok/history/MercurialRepository.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,13 @@ Executor getHistoryLogExecutor(File file, String changeset)
129129
ensureCommand(CMD_PROPERTY_KEY, CMD_FALLBACK);
130130
cmd.add(this.cmd);
131131
cmd.add("log");
132-
if (!file.isDirectory()) { cmd.add("-f"); }
132+
133+
// For plain files we would like to follow the complete history
134+
// (this is necessary for getting the original name in given revision
135+
// when handling renamed files)
136+
if (!file.isDirectory()) {
137+
cmd.add("-f");
138+
}
133139

134140
if (changeset != null) {
135141
cmd.add("-r");

0 commit comments

Comments
 (0)