Skip to content

Commit d4b9acd

Browse files
stefanhallerjesseduffield
authored andcommitted
fixup! Prompt for commit message when moving a custom patch to a new commit
1 parent eddce1f commit d4b9acd

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pkg/gui/controllers/custom_patch_options_menu_action.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,9 @@ func (self *CustomPatchOptionsMenuAction) handlePullPatchIntoNewCommit() error {
186186
commitIndex := self.getPatchCommitIndex()
187187
return self.c.Helpers().Commits.OpenCommitMessagePanel(
188188
&helpers.OpenCommitMessagePanelOpts{
189-
CommitIndex: commitIndex,
189+
// Pass a commit index of one less than the moved-from commit, so that
190+
// you can press up arrow once to recall the original commit message:
191+
CommitIndex: commitIndex - 1,
190192
InitialMessage: "",
191193
SummaryTitle: self.c.Tr.CommitSummaryTitle,
192194
DescriptionTitle: self.c.Tr.CommitDescriptionTitle,

0 commit comments

Comments
 (0)