@@ -35,7 +35,7 @@ import { first } from '../../../../system/iterable';
3535import { Logger } from '../../../../system/logger' ;
3636import { getLogScope } from '../../../../system/logger.scope' ;
3737import type { Git , GitResult } from '../git' ;
38- import { gitDiffDefaultConfigs , GitErrors , gitLogDefaultConfigs } from '../git' ;
38+ import { gitConfigsDiff , gitConfigsLog , GitErrors } from '../git' ;
3939import type { LocalGitProvider } from '../localGitProvider' ;
4040
4141export class DiffGitSubProvider implements GitDiffSubProvider {
@@ -67,7 +67,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
6767
6868 try {
6969 const result = await this . git . exec (
70- { cwd : repoPath , configs : gitDiffDefaultConfigs } ,
70+ { cwd : repoPath , configs : gitConfigsDiff } ,
7171 'diff' ,
7272 '--shortstat' ,
7373 '--no-ext-diff' ,
@@ -137,7 +137,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
137137 let result ;
138138 try {
139139 result = await this . git . exec (
140- { cwd : repoPath , configs : gitLogDefaultConfigs , errors : GitErrorHandling . Throw } ,
140+ { cwd : repoPath , configs : gitConfigsLog , errors : GitErrorHandling . Throw } ,
141141 'diff' ,
142142 ...args ,
143143 args . includes ( '--' ) ? undefined : '--' ,
@@ -159,7 +159,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
159159 @log ( { args : { 1 : false } } )
160160 async getDiffFiles ( repoPath : string , contents : string ) : Promise < GitDiffFiles | undefined > {
161161 const result = await this . git . exec (
162- { cwd : repoPath , configs : gitLogDefaultConfigs , stdin : contents } ,
162+ { cwd : repoPath , configs : gitConfigsLog , stdin : contents } ,
163163 'apply' ,
164164 '--numstat' ,
165165 '--summary' ,
@@ -185,7 +185,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
185185 const similarityThreshold =
186186 options ?. similarityThreshold ?? configuration . get ( 'advanced.similarityThreshold' ) ?? undefined ;
187187 const result = await this . git . exec (
188- { cwd : repoPath , configs : gitDiffDefaultConfigs } ,
188+ { cwd : repoPath , configs : gitConfigsDiff } ,
189189 'diff' ,
190190 '--name-status' ,
191191 `-M${ similarityThreshold == null ? '' : `${ similarityThreshold } %` } ` ,
@@ -263,7 +263,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
263263 // Follow file history and specify the file path
264264 args . push ( '--follow' , '--' , relativePath ) ;
265265
266- const result = await this . git . exec ( { cwd : repoPath , configs : gitLogDefaultConfigs } , ...args ) ;
266+ const result = await this . git . exec ( { cwd : repoPath , configs : gitConfigsLog } , ...args ) ;
267267
268268 let currentSha ;
269269 let currentPath ;
@@ -487,7 +487,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
487487
488488 args . push ( '--follow' , rev ! , '--' , relativePath ) ;
489489
490- const result = await this . git . exec ( { cwd : repoPath , configs : gitLogDefaultConfigs } , ...args ) ;
490+ const result = await this . git . exec ( { cwd : repoPath , configs : gitConfigsLog } , ...args ) ;
491491
492492 let previousSha ;
493493 let previousPath ;
@@ -603,7 +603,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
603603
604604 let result : GitResult < string > ;
605605 try {
606- result = await this . git . exec ( { cwd : repoPath , configs : gitLogDefaultConfigs } , ...args ) ;
606+ result = await this . git . exec ( { cwd : repoPath , configs : gitConfigsLog } , ...args ) ;
607607 } catch ( ex ) {
608608 if ( rev && ! isUncommittedStaged ( rev ) ) throw ex ;
609609
@@ -624,7 +624,7 @@ export class DiffGitSubProvider implements GitDiffSubProvider {
624624 } ;
625625
626626 args . splice ( index , 1 , `-L${ range . startLine } ,${ range . endLine } :${ relativePath } ` ) ;
627- result = await this . git . exec ( { cwd : repoPath , configs : gitLogDefaultConfigs } , ...args ) ;
627+ result = await this . git . exec ( { cwd : repoPath , configs : gitConfigsLog } , ...args ) ;
628628 }
629629
630630 let currentRange ;
@@ -808,7 +808,7 @@ export async function findPathStatusChanged(
808808 const ordering = options ?. ordering ?? configuration . get ( 'advanced.commitOrdering' ) ;
809809
810810 const result = await git . exec (
811- { cwd : repoPath , configs : gitLogDefaultConfigs } ,
811+ { cwd : repoPath , configs : gitConfigsLog } ,
812812 'log' ,
813813 ...parser . arguments ,
814814 ordering ? `--${ ordering } -order` : undefined ,
0 commit comments