diff options
author | Mark Sagi-Kazar <mark.sagikazar@gmail.com> | 2021-11-14 14:31:35 +0100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2021-12-25 12:01:55 +1100 |
commit | fdf0d4a2c3f1112b5b9063ac9a73f18fab2362ef (patch) | |
tree | 2b74a0ddbb3acbbffb30c0e02551ad2bfbf36571 /pkg/gui/files_panel.go | |
parent | b4ea565c99a91f701db24ca5a886da40de84dc0b (diff) |
implement signoff
Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
Diffstat (limited to 'pkg/gui/files_panel.go')
-rw-r--r-- | pkg/gui/files_panel.go | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/pkg/gui/files_panel.go b/pkg/gui/files_panel.go index a6f6a9f08..3bc600420 100644 --- a/pkg/gui/files_panel.go +++ b/pkg/gui/files_panel.go @@ -458,8 +458,14 @@ func (gui *Gui) handleCommitEditorPress() error { return gui.promptToStageAllAndRetry(gui.handleCommitEditorPress) } + args := []string{"commit"} + + if gui.Config.GetUserConfig().Git.Commit.SignOff { + args = append(args, "--signoff") + } + return gui.runSubprocessWithSuspenseAndRefresh( - gui.OSCommand.WithSpan(gui.Tr.Spans.Commit).PrepareSubProcess("git", "commit"), + gui.OSCommand.WithSpan(gui.Tr.Spans.Commit).PrepareSubProcess("git", args...), ) } |