File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ export class GitSCMProvider {
100100 return ;
101101 }
102102
103- return toGitUri ( uri , '' ) ;
103+ return toGitUri ( uri , '' , true ) ;
104104 }
105105
106106 private onDidModelChange ( ) : void {
Original file line number Diff line number Diff line change @@ -12,11 +12,12 @@ export function fromGitUri(uri: Uri): { path: string; ref: string; } {
1212}
1313
1414// As a mitigation for extensions like ESLint showing warnings and errors
15- // for git URIs, let's change the file extension of these uris to .git.
16- export function toGitUri ( uri : Uri , ref : string ) : Uri {
15+ // for git URIs, let's change the file extension of these uris to .git,
16+ // when `replaceFileExtension` is true.
17+ export function toGitUri ( uri : Uri , ref : string , replaceFileExtension = false ) : Uri {
1718 return uri . with ( {
1819 scheme : 'git' ,
19- path : `${ uri . path } .git` ,
20+ path : replaceFileExtension ? `${ uri . path } .git` : uri . path ,
2021 query : JSON . stringify ( {
2122 path : uri . fsPath ,
2223 ref
You can’t perform that action at this time.
0 commit comments