summaryrefslogtreecommitdiffstats
path: root/pkg/commands/git_commands/patch.go
diff options
context:
space:
mode:
authorpikomonde <32364823+pikomonde@users.noreply.github.com>2024-03-21 00:44:56 +0700
committerStefan Haller <stefan@haller-berlin.de>2024-04-12 08:33:47 +0200
commite6ef1642fa0111e075fd14493b913cc4f7098db6 (patch)
treec5c31abe793c3b0b156d84afc28962f091fce9cb /pkg/commands/git_commands/patch.go
parent84333eebc3be466b23627f6709ad6b000ddd21f1 (diff)
rename sha to hash
Diffstat (limited to 'pkg/commands/git_commands/patch.go')
-rw-r--r--pkg/commands/git_commands/patch.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/pkg/commands/git_commands/patch.go b/pkg/commands/git_commands/patch.go
index c632e35ae..b6a8652bc 100644
--- a/pkg/commands/git_commands/patch.go
+++ b/pkg/commands/git_commands/patch.go
@@ -157,13 +157,13 @@ func (self *PatchCommands) MovePatchToSelectedCommit(commits []*models.Commit, s
baseIndex := sourceCommitIdx + 1
changes := []daemon.ChangeTodoAction{
- {Sha: commits[sourceCommitIdx].Sha, NewAction: todo.Edit},
- {Sha: commits[destinationCommitIdx].Sha, NewAction: todo.Edit},
+ {Hash: commits[sourceCommitIdx].Hash, NewAction: todo.Edit},
+ {Hash: commits[destinationCommitIdx].Hash, NewAction: todo.Edit},
}
self.os.LogCommand(logTodoChanges(changes), false)
err := self.rebase.PrepareInteractiveRebaseCommand(PrepareInteractiveRebaseCommandOpts{
- baseShaOrRoot: commits[baseIndex].Sha,
+ baseShaOrRoot: commits[baseIndex].Hash,
overrideEditor: true,
instruction: daemon.NewChangeTodoActionsInstruction(changes),
}).Run()
@@ -219,7 +219,7 @@ func (self *PatchCommands) MovePatchToSelectedCommit(commits []*models.Commit, s
func (self *PatchCommands) MovePatchIntoIndex(commits []*models.Commit, commitIdx int, stash bool) error {
if stash {
- if err := self.stash.Push(self.Tr.StashPrefix + commits[commitIdx].Sha); err != nil {
+ if err := self.stash.Push(self.Tr.StashPrefix + commits[commitIdx].Hash); err != nil {
return err
}
}
@@ -324,7 +324,7 @@ func (self *PatchCommands) diffHeadAgainstCommit(commit *models.Commit) (string,
cmdArgs := NewGitCmd("diff").
Config("diff.noprefix=false").
Arg("--no-ext-diff").
- Arg("HEAD.." + commit.Sha).
+ Arg("HEAD.." + commit.Hash).
ToArgv()
return self.cmd.New(cmdArgs).RunWithOutput()