fix: dont throw away changes

Part of coop-cloud/organising#226.
This commit is contained in:
2021-11-22 21:11:29 +01:00
parent aea5cc69c3
commit dd0f328a65
3 changed files with 5 additions and 5 deletions

View File

@ -76,7 +76,7 @@ func EnsureUpToDate(dir string) error {
refName := fmt.Sprintf("refs/heads/%s", branch)
checkOutOpts := &git.CheckoutOptions{
Create: false,
Force: true,
Keep: true,
Branch: plumbing.ReferenceName(refName),
}
if err := worktree.Checkout(checkOutOpts); err != nil {