This website works better with JavaScript.
Home
Explore
帮助
返回水杉在线
登录水杉在线
登录水杉码园
wlxsp
/
test1
Watch
1
Star
0
Fork
0
Code
Issues
0
Pull Requests
0
Releases
0
Wiki
Activity
Browse Source
Fixes issue with staged/working git documents
main
Eric Amodio
6 years ago
parent
590befa1bc
commit
d85965f7cc
1 changed files
with
17 additions
and
3 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+17
-3
src/git/gitUri.ts
+ 17
- 3
src/git/gitUri.ts
View File
@ -166,12 +166,26 @@ export class GitUri extends ((Uri as any) as UriEx) {
const
repoPath
=
await
git
.
getRepoPath
(
data
.
path
)
;
let
ref
;
switch
(
data
.
ref
)
{
case
''
:
case
'~'
:
ref
=
GitService
.
stagedUncommittedSha
;
break
;
case
null
:
ref
=
undefined
;
break
;
default
:
ref
=
data
.
ref
;
break
;
}
return
new
GitUri
(
uri
,
{
fileName
:
data.path
,
repoPath
:
repoPath
,
sha
:
data.ref
===
''
||
data
.
ref
==
null
?
undefined
:
data
.
ref
sha
:
ref
}
as
IGitCommitInfo
)
;
}
Write
Preview
Loading…
Cancel
Save