1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-01-22 05:29:44 +02:00

4410 Commits

Author SHA1 Message Date
Stefan Haller
c21633b1be Prompt for commit message when moving a custom patch to a new commit 2023-07-23 13:55:48 +02:00
Jesse Duffield
1b05ba252c
Fix crash caused by simultaneous read/write of scanner buffer (#2813) v0.39.3 2023-07-23 13:55:51 +10:00
Jesse Duffield
28474b08ee Fix crash caused by simultaneous read/write of scanner buffer 2023-07-23 13:17:37 +10:00
Jesse Duffield
6f13b42279
Better word wrap (#2812) 2023-07-23 11:46:52 +10:00
Jesse Duffield
8637587b82 Better word wrap
Word wrapping has been pretty bad so far so let's fix that.
2023-07-23 11:43:10 +10:00
Jesse Duffield
f581dc4a56
Update README.md 2023-07-22 15:31:03 +10:00
Jesse Duffield
693e9fc152
Update README.md
Removing unneeded go docs tag
2023-07-22 15:14:18 +10:00
Jesse Duffield
c595833883
Better tag creation UX (#2809) 2023-07-22 14:44:18 +10:00
Jesse Duffield
7807b40322 Better tag creation UX
Previously we used a single-line prompt for a tag annotation. Now we're using the commit message
prompt.

I've had to update other uses of that prompt to allow the summary and description labels to
be passed in
2023-07-22 14:36:35 +10:00
Jesse Duffield
b284970bac
Use fuzzy search when filtering a view (#2808) 2023-07-22 13:17:46 +10:00
Jesse Duffield
b46623ebef Use fuzzy search when filtering a view
This adds fuzzy filtering instead of exact match filtering, which is more forgiving of typos
and allows more efficiency.
2023-07-22 13:14:29 +10:00
Jesse Duffield
084c0a19bc
Include more commit authors in author suggestions (#2807) 2023-07-22 11:00:38 +10:00
Jesse Duffield
3cee37388c Keep track of authors across local commits and branch commits for suggestions
Previously, we would only show the authors based on local commits, but sometimes you want to set a commit author
to that of a commit on another branch. Now, so long as you've viewed the branch's commits, the author will appear
as a suggestion.
2023-07-22 10:47:04 +10:00
Andrew Savinykh
a7969aef2c Fix rendering to main view on windows v0.39.2 2023-07-22 09:14:05 +10:00
Jesse Duffield
39c900c7e7 Fix goreleaser v0.39.1 2023-07-21 09:03:47 +10:00
Jesse Duffield
6e247c1583
Only apply right-alignment on first column of keybindings menu (#2801) v0.39.0 2023-07-20 21:27:01 +10:00
Jesse Duffield
87bf1dbc7f Only apply right-alignment on first column of keybindings menu
Previously we applied a right-align on the first column of _all_ menus, even though we really
only intended for it to be on the first column of the keybindings menu (that you get from pressing
'?')
2023-07-20 21:23:46 +10:00
Jesse Duffield
1f920ae6ba
Fix crash on empty menu (#2799) 2023-07-20 21:17:14 +10:00
Jesse Duffield
932e01b41a Add test for crashing on empty menu 2023-07-20 21:08:56 +10:00
Jesse Duffield
373f24c80f Fix crash on empty menu
When a menu is empty (e.g. due to filtering) we shouldn't crash on focus or selection
2023-07-20 21:05:52 +10:00
Jesse Duffield
a548b289ef
Add missing label to label checker (#2798) 2023-07-20 17:33:10 +10:00
Jesse Duffield
b168fc8cdd Add missing label to label checker 2023-07-20 17:31:40 +10:00
Jesse Duffield
94845dcf98
Update release notes config and add CI check (#2797) 2023-07-20 17:19:49 +10:00
Jesse Duffield
1af6dff64e Update release notes config and add CI check 2023-07-20 17:15:10 +10:00
Jesse Duffield
72de4f436e
Add release config for generating release notes (#2793) 2023-07-19 23:38:04 +10:00
Jesse Duffield
effda8291b Add release config for generating release notes
After going and adding labels for all of these I found out that 'improvement' should be 'enhancement' and 'bugfix' should be 'bug'
but I don't know how to bulk update them (and I can't rename because the desired labels already exist).

I'll work that out later, this is good enough for now
pre-release-0.39-2
2023-07-19 23:37:34 +10:00
Jesse Duffield
7985e31020
Properly fix accordion issue (#2792) pre-release-0.39 2023-07-19 22:24:42 +10:00
Jesse Duffield
866e0a618b Add integration test for accordion mode 2023-07-19 22:17:29 +10:00
Jesse Duffield
a5ee61c117 Properly fix accordion issue
The true issue was that we were focusing the line in the view before it gets resized in the layout function.
This meant if the view was squashed in accordion mode, the view wouldn't know how to set the cursor/origin to
focus the line.

Now we've got a queue of 'after layout' functions i.e. functions to call at the end of the layout function,
right before views are drawn.

The only caveat is that we can't have an infinite buffer so we're arbitrarily capping it at 1000 and dropping
functions if we exceed that limit. But that really should never happen.
2023-07-19 21:16:27 +10:00
Jesse Duffield
08aad924d7
Fix accordion issue (#2791) 2023-07-19 21:07:25 +10:00
Jesse Duffield
be02786dad Fix accordion issue
This fixes the issue in accordion mode where the current line wasn't in the viewport upon focus.

It doesn't perfectly fix it: the current line always appears at the top of the view. But it's good enough
to cut a new release. The proper fix is to only focus the line after the view has had its height adjusted.
2023-07-19 20:39:10 +10:00
README-bot
949022db8c Updated README.md 2023-07-19 08:19:33 +00:00
Stefan Haller
b1a090d4c0
Fix crash when a background fetch prompts for credentials (#2789) 2023-07-19 10:19:18 +02:00
Stefan Haller
39f3f150ed Fix crash when a background fetch prompts for credentials
This happens consistently for my when I close my MacBook's lid. It seems that
MacOS locks the user's keychain in this case, and since I have my keychain
provide the pass phrases for my ssh keys, fetching fails because it tries to
prompt me for a pass phrase.

This all worked correctly already, we have the FailOnCredentialRequest()
mechanism specifically for this situation, so all is great. The only problem was
that it was trying to pause the ongoing task while prompting the user for input;
but the task is nil for a background fetch (and should be).
2023-07-18 18:53:35 +02:00
Stefan Haller
7e9f669421
Show all tags in commits panel (#2776) 2023-07-15 13:11:44 +02:00
Stefan Haller
6b769fb138 Fix populating the Commit.Tags field
We now store all tags in this field if there are several.
2023-07-15 13:07:02 +02:00
Stefan Haller
cc835a813e Extend commit_loader test to show how the Tags field is populated
It shows that right now, we take only the first tag if there are multiple.
Judging from how the code is written, I'm not sure this was intentional.
2023-07-15 13:07:02 +02:00
Stefan Haller
6103a4d13c
Fix potentially wrong help text in commit message panel (#2777) 2023-07-15 13:06:16 +02:00
Stefan Haller
69575dd4f3 Fix potentially wrong help text in commit message panel
It said "Press tab to toggle focus", which is wrong for people who remapped
their togglePanel key binding to something else. Print the actual key binding
instead.
2023-07-15 13:03:13 +02:00
README-bot
bfcff3222c Updated README.md 2023-07-15 06:44:44 +00:00
Jesse Duffield
5adea789d0
Add test for cmd obj cloning (#2780) 2023-07-15 16:44:30 +10:00
Jesse Duffield
78bbdca757 Add test for cmd obj cloning 2023-07-15 11:05:43 +10:00
Stefan Haller
5cb82a49f8
config: rely on .gitconfig for verbose commit messages (#2664)
As discussed in https://github.com/jesseduffield/lazygit/pull/2599, it
makes more sense to have the user specify whether they want verbose
commits from their own git config, rather than lazygit config.

This means that we can remove all the code (including test coverage)
associated with the custom verbose flag, and lazygit will just inherit
the .gitconfig settings automatically.

---

Tested visually locally, as well as running the tests that all pass.
2023-07-14 08:05:22 +02:00
Scott Callaway
9617737352 config: rely on .gitconfig for verbose commit messages
As discussed in https://github.com/jesseduffield/lazygit/pull/2599, it
makes more sense to have the user specify whether they want verbose
commits from their own git config, rather than lazygit config.

This means that we can remove all the code (including test coverage)
associated with the custom verbose flag, and lazygit will just inherit
the .gitconfig settings automatically.
2023-07-14 07:56:09 +02:00
Jesse Duffield
a251f6ad6c
Allow checking for merge conflicts after running a custom command (#2773) 2023-07-13 18:43:25 +10:00
Jesse Duffield
b61ca21a84 Allow checking for merge conflicts after running a custom command
We have a use-case to rebind 'm' to the merge action in the branches panel. There's three ways to handle this:
1) For all global keybindings, define a per-panel key that invokes it
2) Give a name to all controller actions and allow them to be invoked in custom commands
3) Allow checking for merge conflicts after running a custom command so that users can add their own 'git merge' custom command
that matches the in-built action

Option 1 is hairy, Option 2 though good for users introduces new backwards compatibility issues that I don't want to do
right now, and option 3 is trivially easy to implement so that's what I'm doing.

I've put this under an 'after' key so that we can add more things later. I'm imagining other things like being able to
move the cursor to a newly added item etc.

I considered always running this hook by default but I'd rather not: it's matching on the output text and I'd rather something
like that be explicitly opted-into to avoid cases where we erroneously believe that there are conflicts.
2023-07-13 18:40:34 +10:00
README-bot
1ded318666 Updated README.md 2023-07-11 07:22:08 +00:00
Jesse Duffield
e15a99e626
Do not quote initial branch arg when creating repo (#2771) 2023-07-11 17:21:55 +10:00
Jesse Duffield
d4eae73a68 Do not quote initial branch arg when creating repo
Also, we shouldn't pass the initial branch arg if it's empty.
2023-07-11 17:18:58 +10:00
Stefan Haller
5ba1eb2785
Run integration tests with all supported git versions (#2754)
Run integration tests with various different git versions, more or less
randomly picked from our range of supported versions. Based on
@Ryooooooga's work in #2459, but also restructured a bit.

All tests pass for all git versions, but only after cherry-picking
#2747.

I decided to go with @Ryooooooga's approach and do it without using
docker. I also didn't use docker locally; to reproduce the various
failures that I had to fix, I simply installed the respective git
versions locally and used something like
`PATH=~/git-versions/2.25.1/bin:$PATH
./scripts/run_integration_tests.sh`.
2023-07-10 15:13:43 +02:00