Support setting the similarity threshold for detecting renames

This commit is contained in:
István Donkó 2023-09-25 17:32:12 +02:00 committed by Jesse Duffield
parent bfe2dd4ed8
commit b9107d5fc8
26 changed files with 909 additions and 618 deletions

View file

@ -263,6 +263,7 @@ func (self *WorkingTreeCommands) WorktreeFileDiffCmdObj(node models.IFile, plain
Arg(fmt.Sprintf("--unified=%d", contextSize)).
Arg(fmt.Sprintf("--color=%s", colorArg)).
ArgIf(!plain && self.AppState.IgnoreWhitespaceInDiffView, "--ignore-all-space").
Arg(fmt.Sprintf("--find-renames=%d%%", self.AppState.RenameSimilarityThreshold)).
ArgIf(cached, "--cached").
ArgIf(noIndex, "--no-index").
Arg("--").