1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-31 14:24:25 +03:00

Allow setting a default name when creating new branches

This commit is contained in:
Elliot Cubit
2024-04-09 15:41:26 -04:00
committed by Jesse Duffield
parent 436240bbeb
commit 5959f7bc8e
6 changed files with 63 additions and 0 deletions

View File

@ -274,6 +274,10 @@ func (self *RefsHelper) NewBranch(from string, fromFormattedName string, suggest
},
)
if suggestedBranchName == "" {
suggestedBranchName = self.c.UserConfig.Git.BranchPrefix
}
return self.c.Prompt(types.PromptOpts{
Title: message,
InitialContent: suggestedBranchName,