1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-08-07 22:02:56 +03:00

Save and restore the unwrapped description

When preserving the commit message (when cancelling a commit), and later
restoring it, use the unwrapped description.
This commit is contained in:
Stefan Haller
2023-12-20 13:01:41 +01:00
parent cede021400
commit 379a6f1922
3 changed files with 21 additions and 14 deletions

View File

@@ -38,10 +38,14 @@ func (gui *Gui) resetHelpersAndControllers() {
getCommitDescription := func() string {
return strings.TrimSpace(gui.Views.CommitDescription.TextArea.GetContent())
}
getUnwrappedCommitDescription := func() string {
return strings.TrimSpace(gui.Views.CommitDescription.TextArea.GetUnwrappedContent())
}
commitsHelper := helpers.NewCommitsHelper(helperCommon,
getCommitSummary,
setCommitSummary,
getCommitDescription,
getUnwrappedCommitDescription,
setCommitDescription,
)