mirror of
https://github.com/sourcegit-scm/sourcegit.git
synced 2024-12-24 20:57:19 -08:00
fix<Branch>: 修复打开 git svn clone 的 SVN 仓库 崩溃的问题(注意,目前还不支持提交到远程仓库)
This commit is contained in:
parent
643368c6c9
commit
f4a51c79ea
1 changed files with 5 additions and 1 deletions
|
@ -106,7 +106,11 @@ namespace SourceGit.Git {
|
||||||
branch.IsLocal = true;
|
branch.IsLocal = true;
|
||||||
} else if (refname.StartsWith(remotePrefix, StringComparison.Ordinal)) {
|
} else if (refname.StartsWith(remotePrefix, StringComparison.Ordinal)) {
|
||||||
var name = refname.Substring(remotePrefix.Length);
|
var name = refname.Substring(remotePrefix.Length);
|
||||||
branch.Remote = name.Substring(0, name.IndexOf('/'));
|
if (name.Contains("/")) {
|
||||||
|
branch.Remote = name.Substring(0, name.IndexOf('/'));
|
||||||
|
} else {
|
||||||
|
branch.Remote = name;
|
||||||
|
}
|
||||||
branch.Name = name;
|
branch.Name = name;
|
||||||
branch.IsLocal = false;
|
branch.IsLocal = false;
|
||||||
remoteBranches.Add(refname);
|
remoteBranches.Add(refname);
|
||||||
|
|
Loading…
Reference in a new issue