mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-04-23 12:18:51 +02:00
Assume that the base of a worktree can be checked out
This commit is contained in:
parent
2082fdf84a
commit
6f2f9f6677
@ -76,7 +76,8 @@ func (self *WorktreeHelper) NewWorktree() error {
|
|||||||
InitialContent: currentBranchName,
|
InitialContent: currentBranchName,
|
||||||
FindSuggestionsFunc: self.suggestionsHelper.GetRefsSuggestionsFunc(),
|
FindSuggestionsFunc: self.suggestionsHelper.GetRefsSuggestionsFunc(),
|
||||||
HandleConfirm: func(base string) error {
|
HandleConfirm: func(base string) error {
|
||||||
canCheckoutBase := base != currentBranchName
|
// we assume that the base can be checked out
|
||||||
|
canCheckoutBase := true
|
||||||
return self.NewWorktreeCheckout(base, canCheckoutBase, detached)
|
return self.NewWorktreeCheckout(base, canCheckoutBase, detached)
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user