Skip to content

Commit 46c9471

Browse files
authored
Git - fix git status regression for git versions older than 2.18 (microsoft#182739)
* Git - fix git status regression for git versions older than 2.18 * 💄 - Tweak version number
1 parent 6fbd935 commit 46c9471

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

extensions/git/src/git.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2020,7 +2020,8 @@ export class Repository {
20202020
args.push('--ignore-submodules');
20212021
}
20222022

2023-
if (opts?.similarityThreshold) {
2023+
// --find-renames option is only available starting with git 2.18.0
2024+
if (opts?.similarityThreshold && this._git.compareGitVersionTo('2.18.0') !== -1) {
20242025
args.push(`--find-renames=${opts.similarityThreshold}%`);
20252026
}
20262027

0 commit comments

Comments
 (0)