Skip to content
This repository has been archived by the owner on Jul 3, 2020. It is now read-only.

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
OpportunityLiu committed Feb 9, 2020
1 parent 30e7b26 commit c730335
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions EhTagClient/RepoClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,14 @@ private readonly LibGit2Sharp.Handlers.CredentialsHandler CredentialsProvider

public void Pull()
{
Commands.Pull(Repo, new Signature(CommandIdentity, DateTimeOffset.Now), new PullOptions
var remote = Repo.Network.Remotes["origin"];
var refSpecs = remote.FetchRefSpecs.Select(x => x.Specification);
Commands.Fetch(Repo, remote.Name, refSpecs, new FetchOptions
{
FetchOptions = new FetchOptions
{
CredentialsProvider = CredentialsProvider
},
MergeOptions = new MergeOptions
{
}
});
CredentialsProvider = CredentialsProvider
}, "");
var originMaster = Repo.Branches["origin/master"];
Repo.Reset(ResetMode.Hard, originMaster.Tip);
}

public void Commit(string message, Identity author)
Expand Down

0 comments on commit c730335

Please sign in to comment.