summaryrefslogtreecommitdiffstats
path: root/pkg/commands/patch_rebases.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2021-04-10 11:40:42 +1000
committerJesse Duffield <jessedduffield@gmail.com>2021-04-10 11:54:38 +1000
commite42e7e5cbd9d075ee24ae8f91ba9e12bdd42fafc (patch)
tree61d65a544c056b3bf0384cf6954b81b292eb4b07 /pkg/commands/patch_rebases.go
parent93fac1f3124f87009091230f61cc13b5e5473cb5 (diff)
fix commit amend
Diffstat (limited to 'pkg/commands/patch_rebases.go')
-rw-r--r--pkg/commands/patch_rebases.go16
1 files changed, 8 insertions, 8 deletions
diff --git a/pkg/commands/patch_rebases.go b/pkg/commands/patch_rebases.go
index 2c3b5b1d3..6f9e08679 100644
--- a/pkg/commands/patch_rebases.go
+++ b/pkg/commands/patch_rebases.go
@@ -23,7 +23,7 @@ func (c *GitCommand) DeletePatchesFromCommit(commits []*models.Commit, commitInd
}
// time to amend the selected commit
- if _, err := c.AmendHead(); err != nil {
+ if err := c.AmendHead(); err != nil {
return err
}
@@ -51,7 +51,7 @@ func (c *GitCommand) MovePatchToSelectedCommit(commits []*models.Commit, sourceC
}
// amend the destination commit
- if _, err := c.AmendHead(); err != nil {
+ if err := c.AmendHead(); err != nil {
return err
}
@@ -71,7 +71,7 @@ func (c *GitCommand) MovePatchToSelectedCommit(commits []*models.Commit, sourceC
// we can make this GPG thing possible it just means we need to do this in two parts:
// one where we handle the possibility of a credential request, and the other
// where we continue the rebase
- if c.usingGpg() {
+ if c.UsingGpg() {
return errors.New(c.Tr.DisabledForGPG)
}
@@ -103,7 +103,7 @@ func (c *GitCommand) MovePatchToSelectedCommit(commits []*models.Commit, sourceC
}
// amend the source commit
- if _, err := c.AmendHead(); err != nil {
+ if err := c.AmendHead(); err != nil {
return err
}
@@ -122,7 +122,7 @@ func (c *GitCommand) MovePatchToSelectedCommit(commits []*models.Commit, sourceC
}
// amend the destination commit
- if _, err := c.AmendHead(); err != nil {
+ if err := c.AmendHead(); err != nil {
return err
}
@@ -158,7 +158,7 @@ func (c *GitCommand) PullPatchIntoIndex(commits []*models.Commit, commitIdx int,
}
// amend the commit
- if _, err := c.AmendHead(); err != nil {
+ if err := c.AmendHead(); err != nil {
return err
}
@@ -203,7 +203,7 @@ func (c *GitCommand) PullPatchIntoNewCommit(commits []*models.Commit, commitIdx
}
// amend the commit
- if _, err := c.AmendHead(); err != nil {
+ if err := c.AmendHead(); err != nil {
return err
}
@@ -217,7 +217,7 @@ func (c *GitCommand) PullPatchIntoNewCommit(commits []*models.Commit, commitIdx
head_message, _ := c.GetHeadCommitMessage()
new_message := fmt.Sprintf("Split from \"%s\"", head_message)
- _, err := c.Commit(new_message, "")
+ err := c.OSCommand.RunCommand(c.CommitCmdStr(new_message, ""))
if err != nil {
return err
}