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

refactor: Express WithGpgHelper with a config key parameter

This commit is contained in:
Chris McDonnell
2025-03-15 23:12:39 -04:00
committed by Stefan Haller
parent 6fb3b7430c
commit f779a5878d
5 changed files with 28 additions and 10 deletions

View File

@ -6,6 +6,7 @@ import (
"github.com/go-errors/errors"
"github.com/jesseduffield/gocui"
"github.com/jesseduffield/lazygit/pkg/commands/git_commands"
"github.com/jesseduffield/lazygit/pkg/commands/models"
"github.com/jesseduffield/lazygit/pkg/commands/types/enums"
"github.com/jesseduffield/lazygit/pkg/gui/context"
@ -412,6 +413,7 @@ func (self *LocalCommitsController) handleReword(summary string, description str
if models.IsHeadCommit(self.c.Model().Commits, self.c.Contexts().LocalCommits.GetSelectedLineIdx()) {
// we've selected the top commit so no rebase is required
return self.c.Helpers().GPG.WithGpgHandling(self.c.Git().Commit.RewordLastCommit(summary, description),
git_commands.CommitGpgSign,
self.c.Tr.RewordingStatus, nil)
}