mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-22 04:34:59 +00:00
fix(Checkout): never update repository when checkout failed.
This commit is contained in:
parent
8bc23a7d71
commit
fa1a86b7ac
2 changed files with 14 additions and 4 deletions
|
@ -588,7 +588,17 @@ namespace SourceGit.Git {
|
|||
isWatcherDisabled = true;
|
||||
|
||||
var errs = RunCommand($"checkout {option}", null);
|
||||
AssertCommand(errs);
|
||||
if (errs != null) {
|
||||
App.RaiseError(errs);
|
||||
} else {
|
||||
Branches(true);
|
||||
OnBranchChanged?.Invoke();
|
||||
OnCommitsChanged?.Invoke();
|
||||
OnWorkingCopyChanged?.Invoke();
|
||||
OnTagChanged?.Invoke();
|
||||
}
|
||||
|
||||
isWatcherDisabled = false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue