mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-12-01 22:52:01 +02:00
Make it easy to create "amend!" commits
To support this, we turn the confirmation prompt of the "Create fixup commit" command into a menu; creating a fixup commit is the first entry, so that "shift-F, enter" behaves the same as before. But there are additional entries for creating "amend!" commits, either with or without file changes. These make it easy to reword commit messages of existing commits.
This commit is contained in:
@@ -26,9 +26,9 @@ var SquashFixupsAbove = NewIntegrationTest(NewIntegrationTestArgs{
|
||||
NavigateToLine(Contains("commit 02")).
|
||||
Press(keys.Commits.CreateFixupCommit).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Confirmation().
|
||||
t.ExpectPopup().Menu().
|
||||
Title(Equals("Create fixup commit")).
|
||||
Content(Contains("Are you sure you want to create a fixup! commit for commit")).
|
||||
Select(Contains("fixup! commit")).
|
||||
Confirm()
|
||||
}).
|
||||
Lines(
|
||||
|
||||
@@ -25,9 +25,9 @@ var SquashFixupsAboveFirstCommit = NewIntegrationTest(NewIntegrationTestArgs{
|
||||
NavigateToLine(Contains("commit 01")).
|
||||
Press(keys.Commits.CreateFixupCommit).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Confirmation().
|
||||
t.ExpectPopup().Menu().
|
||||
Title(Equals("Create fixup commit")).
|
||||
Content(Contains("Are you sure you want to create a fixup! commit for commit")).
|
||||
Select(Contains("fixup! commit")).
|
||||
Confirm()
|
||||
}).
|
||||
NavigateToLine(Contains("commit 01").DoesNotContain("fixup!")).
|
||||
|
||||
Reference in New Issue
Block a user