1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-06-17 00:18:05 +02:00
Commit Graph

6505 Commits

Author SHA1 Message Date
33d9d4dbf1 Hide waiting status during credentials prompt (#3016) 2023-09-20 13:30:15 +02:00
4c5e250ed8 Add integration test for deleting a remote branch with credentials prompt
This test is interesting because it shows a credentials prompt inside a
WithWaitingStatus. Prior to this branch this test would have hung forever.
2023-09-20 13:29:30 +02:00
1359fa14c1 When pausing a task during a waiting status, hide the status while paused
We do this for two reasons:
- when popping up a credentials prompt, it looks distracting if the waiting
  status keeps spinning while the user is typing the password
- the task that updates the waiting status periodically would keep the program
  busy, so integration tests would wait forever for the program to become idle
  again
2023-09-20 13:29:30 +02:00
c222a618a8 Extract WaitingStatusHandle 2023-09-20 13:29:11 +02:00
05c32e292e Extract StatusManager.addStatus method
Avoids a bit of code duplication.
2023-09-20 11:27:50 +02:00
fb4f742416 Updated README.md 2023-09-20 06:10:06 +00:00
276438b601 Add history for search view (#2877) 2023-09-20 16:09:53 +10:00
edec116ceb Add search history
Add search history for filterable and searchable views.
2023-09-20 08:35:41 +03:00
1aae1772ce Allow cherry-picking commits during a rebase (#3013) 2023-09-19 07:15:10 +02:00
a642395e9f Allow cherry-picking commits during a rebase
This can be useful when you know that a cherry-picked commit would conflict at
the tip of your branch, but doesn't at the beginning of the branch (or
somewhere in the middle). In that case you want to be able to edit the commit
before where you want to insert the cherry-picked commits, and then paste to
insert them into the todo list at that point.
2023-09-18 10:50:19 +02:00
70bfeddc90 Add StatusCommands.IsInNormalRebase and IsInInteractiveRebase
... and implement RebaseMode in terms of these.
2023-09-18 10:50:19 +02:00
e2a966443b Add a DisabledReason mechanism for menu items and keybindings (#2992) 2023-09-18 10:26:11 +02:00
0b13c3ca87 Disabled paste when there are no copied commits 2023-09-18 10:20:23 +02:00
8b6766de79 Use DisabledReason for commits panel commands 2023-09-18 10:20:23 +02:00
c9371f812f Use DisabledReason for rebasing a branch onto itself 2023-09-18 10:20:23 +02:00
e592d81b60 Add Enabled func to Binding 2023-09-18 10:20:23 +02:00
f2f50ccf75 Use DisabledReason for upstream options items 2023-09-18 10:15:11 +02:00
75aed98c35 Use DisabledReason when deleting branches is not possible
Two cases: trying to delete the currently checked-out branch, or deleting the
upstream of a branch that doesn't have one.
2023-09-18 10:15:11 +02:00
7f9818cfa2 Add DisabledReason field to MenuItem
This is useful to disable items that are not applicable right now because of
some condition (e.g. the "delete branch" menu item when the currently
checked-out branch is selected).

When a DisabledReason is set on a menu item, we
- show it in a tooltip (below the regular tooltip of the item, if it has one)
- strike through the item's key, if it has one
- show an error message with the DisabledReason if the user tries to invoke the
  command
2023-09-18 10:15:11 +02:00
679148449a Updated README.md 2023-09-18 08:14:59 +00:00
bc00aeb10d Rename test/results to test/_results (#3012) 2023-09-18 10:14:43 +02:00
4d258bd981 Use UpstreamBranch for opening pull requests 2023-09-18 13:40:52 +10:00
c465b0f2ff Rename test/results to test/_results
This prevents commands like "go test ./..." from looking into it, and it
prevents VS Code's Problems panel from showing errors about the go files in that
folder.
2023-09-15 18:04:20 +02:00
25160b671e Updated README.md 2023-09-13 07:17:12 +00:00
20bfa42792 Use Error method to handle commits url copy from unknown service (#3007) 2023-09-13 17:16:53 +10:00
5a740e34c7 fix: use Error method to handle the commit url copy from unknown service 2023-09-12 19:06:08 +02:00
0aad599a9b Various debugging improvements (#3000) 2023-09-11 08:27:03 +02:00
b6c892a08a Provide a simple way to debug an integration test 2023-09-11 08:17:58 +02:00
28d12e4e5d Add debug configuration to attach to a running lazygit process
I often find it more convenient to start a lazygit process in a terminal window
and then attach to it, rather than have VS Code launch one for me.

Note that this doesn't work with "go run main.go". It does work with "make run",
however.

Make sure there's only one lazygit process running, otherwise VS Code will open
a chooser with all the running processes to pick one from, but it's pretty much
impossible to tell which is which.
2023-09-10 11:47:25 +02:00
5d5e24a48e Change "make run" to do a build and then launch lazygit
As far as I can tell, there's not much of a difference in behavior between the
two. The advantage of doing it this way is that you can attach a debugger to the
running lazygit process; see next commit.
2023-09-10 11:47:25 +02:00
de598e55a6 Hide system goroutines in callstack
I have never found a reason to see them, and they just pollute the stack window
unnecessarily.
2023-09-10 11:47:25 +02:00
0fd8392067 Format launch.json with Prettier 2023-09-10 11:47:25 +02:00
67ac2c5d9b Change the default of the "gui.borders" config to "rounded" (#2998) 2023-09-10 12:23:25 +10:00
7626fd7df3 Add co-author to commits (#2912) 2023-09-10 11:38:16 +10:00
db409fa69f Add coauthor (#2)
Add co-author to commits

Add addCoAuthor command for commits

- Implement the `addCoAuthor` command to add co-authors to commits.
- Utilize suggestions helpers to populate author names from the suggestions list.
- Added command to gui at `LocalCommitsController`.

This commit introduces the `addCoAuthor` command, which allows users to easily add co-authors to their commits. The co-author names are populated from the suggestions list, minimizing the chances of user input errors. The co-authors are added using the Co-authored-by metadata format recognized by GitHub and GitLab.
2023-09-09 07:18:47 -05:00
5b8a8d356c Change the default of the "gui.borders" config to "rounded"
Most people seem to agree that it looks better than the sharp edges of "single".
2023-09-09 10:42:24 +02:00
d7e2ca3f10 Add jump-to-panel label config setting (#2993) 2023-09-09 09:55:52 +02:00
387fbf6ab6 feat: add jump-to-panel label setting 2023-09-09 09:45:08 +02:00
917eb88617 Bump gocui 2023-09-09 09:44:50 +02:00
005827395d Updated README.md 2023-09-09 07:35:14 +00:00
7f9fa64074 Replace whitespace with '-' when renaming a branch (#2990) 2023-09-09 17:34:57 +10:00
ab06a1c85c Updated README.md 2023-09-06 06:45:15 +00:00
37048911ca Support to reset the current branch to a selected branch upstream (#2940) 2023-09-06 08:45:00 +02:00
2b7b6f71ee feat: add a menu to reset current branch to a target branch upstream 2023-09-06 08:40:07 +02:00
47d422bb8a chore: rename "Set/Unset upstream" menu to "Upstream Options"
This should already have been done when adding the "View divergence from
upstream" command, but now we're going to add yet another item to the menu that
is unrelated to setting or unsetting the upstream.
2023-09-06 00:23:35 +02:00
c3ca77d6bf Replace whitespace with '-' when renaming a branch 2023-09-05 14:57:18 +01:00
a3cd1e93be Updated README.md 2023-09-05 12:01:12 +00:00
4cf8d81155 Save diff context size in state.yml instead of config.yml (#2969) 2023-09-05 14:00:55 +02:00
7774fe0ab3 Move diff context size from UserConfig to AppState 2023-09-05 13:55:30 +02:00
f7db17f7d0 Load defaults for AppState before reading from yaml
So far this hasn't been necessary because all defaults were zero values. We're
about to add the first non-zero value though, and it's important that it is
initialized correctly for users who have a state.yml that doesn't have it yet.
2023-09-04 17:50:49 +02:00