mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-07-03 00:57:52 +02:00
Added initialContent on branch rename
This commit is contained in:
committed by
Jesse Duffield
parent
c43416891e
commit
52d5c3beeb
@ -435,6 +435,7 @@ func (gui *Gui) handleRenameBranch(g *gocui.Gui, v *gocui.View) error {
|
|||||||
promptForNewName := func() error {
|
promptForNewName := func() error {
|
||||||
return gui.prompt(promptOpts{
|
return gui.prompt(promptOpts{
|
||||||
title: gui.Tr.NewBranchNamePrompt + " " + branch.Name + ":",
|
title: gui.Tr.NewBranchNamePrompt + " " + branch.Name + ":",
|
||||||
|
initialContent: branch.Name,
|
||||||
handleConfirm: func(newBranchName string) error {
|
handleConfirm: func(newBranchName string) error {
|
||||||
if err := gui.GitCommand.RenameBranch(branch.Name, newBranchName); err != nil {
|
if err := gui.GitCommand.RenameBranch(branch.Name, newBranchName); err != nil {
|
||||||
return gui.surfaceError(err)
|
return gui.surfaceError(err)
|
||||||
|
Reference in New Issue
Block a user