1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-06-21 00:30:00 +02:00

Implement moving commits up/down in terms of daemon

This commit is contained in:
Stefan Haller
2023-04-06 09:53:10 +02:00
parent 3791f0b2fa
commit dad7a70bf8
3 changed files with 47 additions and 8 deletions

View File

@ -440,7 +440,7 @@ func (self *LocalCommitsController) moveUp(commit *models.Commit) error {
return self.c.WithWaitingStatus(self.c.Tr.MovingStatus, func() error {
self.c.LogAction(self.c.Tr.Actions.MoveCommitUp)
err := self.git.Rebase.MoveCommitDown(self.model.Commits, index-1)
err := self.git.Rebase.MoveCommitUp(self.model.Commits, index)
if err == nil {
self.context().MoveSelectedLine(-1)
}