Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use git rev-parse to obtain repository and worktree paths #3183

Merged

Conversation

jwhitley
Copy link
Contributor

  • PR Description
    This changes GetRepoPaths() to pull information from git rev-parse instead of partially reimplementing git's logic for pathfinding. This change fixes issues with bare repos, esp. versioned homedir use cases, by aligning lazygit's path handling to what git itself does. I believe it also paves the way for lazygit to run from any subdirectory of a working tree with relatively minor changes.

Addresses #1294 and #3175.

  • Please check if the PR fulfills these requirements
  • Cheatsheets are up-to-date (run go generate ./...)
  • Code has been formatted (see here)
  • Tests have been added/updated (see here for the integration test guide)
  • Text is internationalised (see here)
  • Docs (specifically docs/Config.md) have been updated if necessary
  • You've read through your own file changes for silly mistakes etc

@jwhitley
Copy link
Contributor Author

A note on tests: some of tests in repo_path_tests.go didn't "survive" these changes as they no longer made sense. For example, "worktree with trailing separator in path" is transparently handled by git itself (I checked) so there's no reason to retest that git implements its own behavior.

I believe that the revised tests support the changed code reasonably well, but would appreciate feedback here due to the overall magnitude of the shift to the implementation.

@jwhitley
Copy link
Contributor Author

One more thing. To support this work I created a shell script gist: repotest.zsh that uses git to replicate therepo_paths_test.go scenarios in actual git repos, and to vet out populating the RepoPaths struct via git rev-parse. Perhaps it would be helpful to inform eventual integation tests?

@stefanhaller
Copy link
Collaborator

Thanks, this looks awesome at first glance. I don't have time for an in-depth review today, but I'm also not sure I'm the best person to review this anyway. I'm not familiar with worktrees at all, Jesse wrote all that code, and I think it would be best to wait for him to be back.

@jwhitley
Copy link
Contributor Author

Thanks. In the meantime it looks like code coverage CI failed because it didn’t run. Do you have any insight into that? If there are any coverage issues, it would be nice to sort those out ASAP.

@stefanhaller stefanhaller added the bug Something isn't working label Dec 27, 2023
@stefanhaller
Copy link
Collaborator

In the meantime it looks like code coverage CI failed because it didn’t run. Do you have any insight into that?

That's a know problem, see #3039 (comment) and #3039 (comment).

@jwhitley
Copy link
Contributor Author

I ran the coverage manually, and there are two things that show up:

  1. The current tests only hit the error case for the first git rev-parse call, but not the subsequent ones. This was a "known" choice, mostly as the realistic scenario is that git bails on making sense of the repo on the first call, but I'm open to revising it. For 100% coverage, there would need to be cases that failed each successive git call.
  2. linkedWorktreePaths() only has partial coverage now, through the first error return, but missing the main loop. I suspect it was getting coverage in passing before, but now it's only called via worktree_loader.go. So direct test(s) may be in order.

@stefanhaller
Copy link
Collaborator

Don't sweat it too much, 100% test coverage is not a goal here. The decision whether a branch in your code deserves to be covered by a test is a judgement call, we don't want tools to dictate this.

We added the coverage check to CI mainly as an experiment to see if it's useful for catching the case that someone adds a whole new feature without tests. Personally I'm not convinced of that at all, this will always be caught by human reviews too. But the experiment is still ongoing.

@jwhitley
Copy link
Contributor Author

jwhitley commented Jan 2, 2024

Related to finding missed edge cases related to this PR, #1865 jumped out at me. The tl;dr of its scenario is: create a repo that has two-level nested submodules, then deep link into the "inner" submodule. cd into the link, and lazygit will show the wrong repo root, skipping the "outer" submodule. I updated the repotest.zsh script (see gist link above) to recreate this case. git, as expected, shows all of the correct values. i.e. this PR will correctly populate RepoPaths. So some other code is the problem.

Repro steps:

  1. Grab the updated repotest.zsh code (2nd commit on that gist, at this writing).
  2. run it via env DEBUG=1 ./repotest.zsh doubleLinkedSubmoduleCase. That will build the test repo under /tmp/lazygitRepoPath.XXXX ('XXXX' will be random; the script prints the actual path for you). The nested structure is repo/outerSubmodule/innerSubmodule, with a link in repo cLink@ -> outerSubmodule/innerSubmodule/a/b/c
  3. cd into /tmp/lazygitRepoPath.XXXX/repo/cLink.
  4. Run lazygit (built from the first commit on this PR).

lazygit will incorrectly show repo for the current repository, since it walked up /path/to/repo/cLink to /path/to/repo. It should show that it's in innerSubmodule.

The root cause (in git.go) is that NewGitCommand()'s calls findWorktreeRoot(), which walks up the directory tree looking for the worktree root without first calling filepath.EvalSymlinks(currentPath). A local patch that makes that call completely fixes #1865. i.e. In the current code symlinks can confuse the .git dir search, since they can skip nested submodule levels. That's the first-order bug. But I think there are deeper issues worth considering:

  1. If an ostensible goal of this PR is "delegate pathfinding policy to git", then NewGitCommand() should theoretically just call out to git rev-parse --show-toplevel. It's definitely another reimplementaton of that logic, which is one view on why there's a bug. But calling git from a command intended to call git would be a weird thing to do. And there's a lot of code in the world that walks up to the root dir looking for some config file/dir. Pragmatically, I think this is probably OK.
  2. NewGitCommand() calls os.Chdir(currentPath). IMO, it's worth thinking about whether a "new" call should mutate app state like this, especially when git itself doesn't care because it always does this kind of path resolution. Some lazygit code may care, e.g. diffing or whatever, but that could theoretically just cd to the current repoPaths.worktreePath. (again pragmatically, the answer here might be "there's been too much pain playing current-directory-whack-a-mole, this code just normalizes the current directory 100% of the time".) I acknowledge that I don't have enough app-wide context here, but thought the question worth considering.

I'm going to submit the EvalSymlink patch as an additional commit to this PR shortly, since I've talked myself into thinking it's almost certainly the right thing to do at this moment.

@jwhitley
Copy link
Contributor Author

jwhitley commented Jan 2, 2024

Re: the prior comment, see also discussion on #3017.

I just submitted a commit that adds an EvalSymlinks call. Since afero MemMapFS doesn't support symlinks, I just skip symlink evaluation if MemMapFS is in use. The alternative would be to do what repo_paths.go used to do: use a symlink eval function which is replaced with a stub in test. If we want to go that way, I propose adding that into Common alongside afero Fs, so the two can be changed simultaneously as needed. Probably just add a new interface with associated implementations, ala:

type Symlinks interface {
  EvalSymlinks(path string) (string , error)
}

@jwhitley
Copy link
Contributor Author

jwhitley commented Jan 3, 2024

YES! I finally nailed what appears to be the last known issue with lazygit running from an arbitrary directory of the working tree: diff-ish git commands were being run from CWD, not from the root, but were being passed root-relative paths. Incoming commit will fix this by adding the Dir(self.repoPaths.worktreePath) directive to the relevant command builder invocations. Preliminary testing shows this working very nicely, including in "exotic" bare-repo versioned homedir cases. I need to fully inspect failing tests, mostly fixing up ones which aren't expecting the new -C args. Commit incoming soon...

I'll appreciate a little extra scrutiny on this specific change when it lands, since I'm not 100% sure I've hit every necessary invocation, nor am I positive that I know how to manually inspect each change via the UI just yet.

@jwhitley
Copy link
Contributor Author

jwhitley commented Jan 3, 2024

OK, I have nothing more incoming on this branch. I believe it fixes every known issue I've found on my own and by scraping the issues (not completely!!), involving repo variants (bare, "fake" bare, submodules, weird nested things, etc) that git itself handles but were lazygit edge cases. Further, lazygit is now also running cleanly from arbitrary subdirectories, including symlink behavior, and the above repo variants.

If anyone finds any misses on those goals, throw 'em my way and I'll crush 'em! 💪🏼

If it's helpful, I'd consider a follow-on PR that adds repo structure variants from the current version of repotest.zsh to the integration tests. High-level pointers there would be helpful (e.g. "look at these tests first for examples").

Copy link
Owner

@jesseduffield jesseduffield left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome work. Leaving git to do the work is a much better option than doing it manually ourselves and this should make things much more reliable in the future.

I've left some comments around implementation. As for testing, it would be good to add an integration test for each issue that this PR intends to fix. Let me know if you need any guidance on that. An example integration test that deals with similar functionality is pkg/integration/tests/worktree/dotfile_bare_repo.go. You can also pass ExtraEnvVars to NewIntegrationTestArgs if your test depends on specific environment variables.

pkg/commands/git_commands/repo_paths.go Outdated Show resolved Hide resolved
pkg/commands/git_commands/repo_paths.go Outdated Show resolved Hide resolved
pkg/commands/git_commands/worktree_loader.go Outdated Show resolved Hide resolved
pkg/tasks/tasks.go Outdated Show resolved Hide resolved
pkg/commands/git.go Outdated Show resolved Hide resolved
pkg/commands/git.go Outdated Show resolved Hide resolved
@jwhitley
Copy link
Contributor Author

ARGH. This repo doesn't have a .editorconfig file. In principle gofumpt/gofmt should be picking up the slack here, but for some reason my local config isn't doing that correctly now. Either way, it's nice to have the default editing (indenting!) experience mostly match the formatting results. I'll add a minimal one (only for [*.go] files) to this branch; can remove it if not desired for some reason.

Copy link
Owner

@jesseduffield jesseduffield left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know you haven't requested a re-review yet but I thought I'd add some more comments on the back of your recent changes

pkg/commands/git_commands/repo_paths_test.go Show resolved Hide resolved
pkg/commands/git_commands/worktree_loader.go Show resolved Hide resolved
.editorconfig Show resolved Hide resolved
@jwhitley
Copy link
Contributor Author

jwhitley commented Jan 11, 2024

@jesseduffield I've added the first integration test, aimed at capturing my real-world case that prompted #3175. The problem is that it doesn't fail on master or v0.40.2 (the latest release I have handy, via Homebrew).

EDIT: I did confirm that the test has UseCustomPath: true so that --work-tree won't be implicitly set.

I re-confirmed that v0.40.2 crashes on startup via the repro steps:

  1. Download the current version of repotest.zsh
  2. Invoke it as: env DEBUG=1 ./repotest.zsh fakeBareRepoCase
    a. The last line of output shows the temp directory used for this case.
  3. cd to the temp directory in step 2a.
  4. run export GIT_DIR=`realpath ./bareRepo.git`
  5. lazygit

Observe a crash ala:

>> /opt/homebrew/bin/lazygit                                                                                                                                                                                                                18.17.1
2024/01/11 14:33:18 An error occurred! Please create an issue at: https://github.com/jesseduffield/lazygit/issues

*errors.errorString Error getting repo paths: failed to get worktree git dir path: stat /tmp/lazygitRepoPath.J8eOWO/a/b/c/.git: no such file or directory
github.com/jesseduffield/lazygit/pkg/commands/git.go:100 (0x100eef2b8)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:271 (0x1010152ac)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:656 (0x101017c00)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:675 (0x101018200)
github.com/jesseduffield/lazygit/pkg/utils/utils.go:108 (0x100d92960)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:674 (0x10101816c)
github.com/jesseduffield/lazygit/pkg/app/app.go:263 (0x1010404bc)
github.com/jesseduffield/lazygit/pkg/app/app.go:48 (0x101040481)
github.com/jesseduffield/lazygit/pkg/app/entry_point.go:150 (0x10104208c)
github.com/jesseduffield/lazygit/main.go:23 (0x101043858)
runtime/internal/atomic/types.go:194 (0x100a1eafc)
runtime/asm_arm64.s:1197 (0x100a50434)

AFAICT, the test in the latest commit should correctly replicate the fakeBareRepoCase setup. I suspect that something about the test environment may be preventing the crash. Do you have any insight on that?

@jwhitley
Copy link
Contributor Author

jwhitley commented Jan 11, 2024

For clarity, here's my plan for new integration tests.

Issues fixed:

#1294 - dotfile bare repo "omnibus" issue
#1865 - two-level nested submodules
#3015 - fixed since git itself evaluates symlinks in git rev-parse (here for --git-dir)
#3144 - lg errors when opened from symlink'ed path (outside of repo) to dir inside of repo
#3175 - Similar dotfile case, $GIT_DIR is set (via --git-dir arg) but --work-tree/$GIT_WORK_TREE is unset

New lazygit integration tests

(EDIT: GitHub's long-form autolinking inside (check)lists was making this unreadable; switched to manual links. –J)

  • #3175 - Similar to bare_repo.go, but --git-dir is set, --work-tree is unset, but core.worktree on the bare repo is set.
    • #1294 isn't really an issue with lazygit (see my comment), but various commenters have bare-repo issues covered by #3175
  • #3144 - Setup repo with subdir, symlink into that subdir, run lg from it
    • #3015 is a dupe of #3144
  • #1865 - integration test matching repotest.zsh's doubleLinkedSubmoduleCase (discussed in detail above)

@jwhitley
Copy link
Contributor Author

Learning about the integration test setup: The crash below is from 0.40.2 run from the repo constructed by the test, with GIT_DIR set as per the test. The branch build works as expected. Stronger confirmation of some misalignment of the test environment vs. the built application. I've been digging through {test,runner,shell}.go, but no obvious causes have popped up.

>> /opt/homebrew/bin/lazygit
2024/01/11 16:37:28 An error occurred! Please create an issue at: https://github.com/jesseduffield/lazygit/issues

*errors.errorString Error getting repo paths: failed to get worktree git dir path: stat /Users/whitley/src/3p/lazygit/1/test/_results/worktree/bare_repo_worktree_config/actual/a/b/c/.git: no such file or directory
github.com/jesseduffield/lazygit/pkg/commands/git.go:100 (0x10519f2b8)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:271 (0x1052c52ac)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:656 (0x1052c7c00)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:675 (0x1052c8200)
github.com/jesseduffield/lazygit/pkg/utils/utils.go:108 (0x105042960)
github.com/jesseduffield/lazygit/pkg/gui/gui.go:674 (0x1052c816c)
github.com/jesseduffield/lazygit/pkg/app/app.go:263 (0x1052f04bc)
github.com/jesseduffield/lazygit/pkg/app/app.go:48 (0x1052f0481)
github.com/jesseduffield/lazygit/pkg/app/entry_point.go:150 (0x1052f208c)
github.com/jesseduffield/lazygit/main.go:23 (0x1052f3858)
runtime/internal/atomic/types.go:194 (0x104cceafc)
runtime/asm_arm64.s:1197 (0x104d00434)

@jesseduffield
Copy link
Owner

I spent some time looking into this and it turns out that the difference between the manual and the automated test is that the current working directory is not set by the automated test, meaning it defaults to the lazygit root directory.

Regrettably, we actually depend on this working tree being set so that it can look up the test to run internally. Specifically, in GetTests() in pkg/integration/tests/tests.go we call utils.GetLazyRootDirectory() to find the lazygit root in order to find the tests. And that function (defined in vendor/github.com/jesseduffield/lazycore/pkg/utils/utils.go) just looks for a .git directory (as opposed to looking for a folder called 'lazygit' for example)!

This is why we're passing '--path' instead of setting the working directory.

I've got a PR up to fix this: #3215

If you add that to your branch, your test should fail properly on master (tested this myself locally). You'll need to remove the UseCustomPath part from the test as that's no longer a thing.

@jwhitley
Copy link
Contributor Author

Awesome, thanks @jesseduffield. I rebased my local branch and confirmed that I get the expected failure on master with this test.

Next wrinkle: this test starts lazygit in a subdir of the repo (a/b/c) then tries to add (a/b/c/blah) to pick up an update. This operation fails because lazygit isn't accounting for CWD being below the repo-root when it invokes git. (Clearly my manual testing was trash .. I would have sworn I'd exercised this manually. :-pppp mumbles in "why test plans exist") A generalized sequence of events:

  1. cd /path/to/repo/a/b/c
  2. modify a/b/c/blah
  3. start lazygit (from this branch)
  4. Tap space to add blah

A warning dialog like the one below appears, and the command window shows that we're trying to git add -- a/b/c (while CWD is already a/b/c). Note that the 'a' (add all) command works fine because it's not passed any file paths.

Screenshot 2024-01-12 at 7 29 36 AM

I'll chew on this one today, but it means that there's a whole class of issues I clearly missed w.r.t. subdirectory correctness. lazygit is always passing single files as root-relative paths. That means, one way or another, git needs to know where the repo root is:

  1. either because paths are always relative to CWD (how a human on the CLI often works)
  2. because CWD or -C options tell git where the root is.

It feels like a big change to plumb -C to every relevant git invocation. An alternative is for lazygit to explicitly manage CWD state by always cd'ing to RepoPaths.worktreePath for the current worktree. Any other required cd operations must then save/restore that state. That sets environmental context for all git commands, which should be a smaller code change but still a "big" operational change.

As I said, I'll think on this one today. If you have feelings about the best path forward here, (including "put it off to a follow-on PR"), I'd love to hear.

@jesseduffield
Copy link
Owner

It feels like a big change to plumb -C to every relevant git invocation. An alternative is for lazygit to explicitly manage CWD state by always cd'ing to RepoPaths.worktreePath for the current worktree. Any other required cd operations must then save/restore that state. That sets environmental context for all git commands, which should be a smaller code change but still a "big" operational change.

As I said, I'll think on this one today. If you have feelings about the best path forward here, (including "put it off to a follow-on PR"), I'd love to hear.

Hmm. So in pkg/app/entry_point.go we currently set the CWD if --path or --work-tree is passed, but in this case only --git-dir is being passed so we leave the CWD to be whatever lazygit is opened in. So I think we should just also change the CWD to the worktree root if --git-dir is passed. I don't expect that to be a big change at all, given that we're already doing it with the other cases. The tricky part is picking the right place to do this: I suspect pkg/app/entry_point.go is the wrong place given that we don't obtain the repo paths until later. How about in the first leg of this if statement in NewGitCommand?

    // pkg/commands/git.go
	gitDir := env.GetGitDirEnv()
	if gitDir != "" {
		// we've been given the git directory explicitly so no need to navigate to it
		_, err := cmn.Fs.Stat(gitDir)
		if err != nil {
			return nil, utils.WrapError(err)
		}
	} else {
		// we haven't been given the git dir explicitly so we assume it's in the current working directory as `.git/` (or an ancestor directory)

		rootDirectory, err := findWorktreeRoot(cmn.Fs, currentPath)
		if err != nil {
			return nil, utils.WrapError(err)
		}
		currentPath = rootDirectory
		err = os.Chdir(rootDirectory)
		if err != nil {
			return nil, utils.WrapError(err)
		}
	}

	repoPaths, err := git_commands.GetRepoPaths(cmn.Fs, currentPath)
	if err != nil {
		return nil, errors.Errorf("Error getting repo paths: %v", err)
	}

@jwhitley
Copy link
Contributor Author

That's hugely helpful. It turns out there's an even simpler approach with the new GetRepoPaths(). That whole chunk of code in NewGitCommand() reduces to the snippet below. The principle is the same behind the GetRepoPaths() refactor: git handles all of this logic for us already, so just let it. With one additional (completely orthogonal) change below, all unit and integration tests (and the new test) pass:

	// converting to forward slashes for the sake of windows (which uses backwards slashes). We want everything
	// to have forward slashes internally
	currentPath = filepath.ToSlash(currentPath)

	repoPaths, err := git_commands.GetRepoPaths(osCommand.Cmd, currentPath)
	if err != nil {
		return nil, errors.Errorf("Error getting repo paths: %v", err)
	}
	currentPath = repoPaths.WorktreePath()

	err = os.Chdir(currentPath)
	if err != nil {
		return nil, utils.WrapError(err)
	}

Separately, I noted that pkg/integration/tests/commit/commit_switch_to_editor.go was failing for me. It turns out that $GIT_EDITOR overrides core.editor, causing this test to invoke my neovim setup rather than the stubbed-in test "editor". I've added a commit to fix that by outright unsetting GIT_EDITOR in cmd/integration_test/main.go.

@jesseduffield
Copy link
Owner

Great work, that's much simpler.

As for GIT_EDITOR, I think we should be fixing this issue at the source, which is that in getLazygitCommand in pkg/integration/components/runner.go we instantiate the command object like cmdObj := osCommand.Cmd.New(cmdArgs) and New does cmd.Env = os.Environ(). So lazygit is inheriting all the env vars from the environment. I think that in pkg/commands/oscommands/cmd_obj_builder.go we should have:

func (self *CmdObjBuilder) New(args []string) ICmdObj {
	cmdObj := self.NewWithoutEnviron(args)
	cmdObj.GetCmd().Env = os.Environ()
	return cmdObj
}

func (self *CmdObjBuilder) NewWithoutEnviron(args []string) ICmdObj {
	cmd := exec.Command(args[0], args[1:]...)

	return &CmdObj{
		cmd:    cmd,
		runner: self.runner,
	}
}

And then in pkg/integration/components/runner.go we should go:

cmdObj := osCommand.Cmd.NewWithoutEnviron(cmdArgs)

That way, we'll have full control over what environment variables are set in the test lazygit process, and there won't be any difference between dev machines or CI.

@jesseduffield
Copy link
Owner

Whoops my bad, I missed that part of the code. Not able to look closely right now but I assume this is the crux of it:

func (self *WorktreeHelper) GetLinkedWorktreeName() string {
	worktrees := self.c.Model().Worktrees
	if len(worktrees) == 0 {
		return ""
	}

	// worktrees always have the current worktree on top
	currentWorktree := worktrees[0]
	if currentWorktree.IsMain {
		return ""
	}

	return currentWorktree.Name
}

@jwhitley
Copy link
Contributor Author

Thanks Jesse. I skimmed around through the code with that as a starting point, but nothing obvious popped up. I'll have a go at debugging into it in the morning.

@jwhitley
Copy link
Contributor Author

OK, I just goofed the recent change to apply filepath.Abs in GetRepoPaths – used it on the wrong field. <facepalm.gif> That's fixed in the latest change, and integration tests now pass locally on git 2.20.0 and 2.43.0. I didn't add a unit test for this specific case. It would require passing a mock function for filepath.Abs during test since it turns out that filepath.Abs will always hit the real filesystem if given a relative path (but not for an already-absolute path). Let me know what you all think about unit coverage for this.

@stefanhaller
Copy link
Collaborator

All tests are green! Nice. There's one linter error though, please have a look.

I don't have an opinion about the unit test question.

@jwhitley
Copy link
Contributor Author

There's one linter error though, please have a look.

Good grief, missed some newly-dead code when removing currentPath from RepoPaths. Fixed in latest commit.

@jwhitley
Copy link
Contributor Author

Allright, I also fixed up some default-disabled analyses in gopls that were default re-enabled by my Neovim gopls/LSP plugin. That was producing a lot of noise, so I wasn't always paying as much attention to diagnostics (e.g. that lint error) as I should.

@jesseduffield
Copy link
Owner

jesseduffield commented Jan 19, 2024

One last thing before merging: any chance you're a windows user @jwhitley ? Cos we wanna ensure this works on windows (regrettably we have yet to get integration tests working on windows in CI)

@jwhitley
Copy link
Contributor Author

One last thing before merging: any chance you're a windows user @jwhitley ? Cos we wanna ensure this works on windows (regrettably we have yet to get integration tests working on windows in CI)

I'll see what I can do. I have a Windows 10 VM that should work for this, but it's never been setup for anything like dev work.

@jwhitley
Copy link
Contributor Author

Hmm.. I think something about my setup is incomplete or borked. It's looking like the integration tests all fail with the same error:

go run .\cmd\integration_test\main.go cli .\pkg\integration\tests\bisect\skip.go
panic: runtime error: index out of range [1] with length 1

goroutine 1 [running]:
github.com/jesseduffield/lazygit/pkg/integration/components.TestNameFromFilePath({0x40000c6500?, 0x42?})
        C:/Users/whitley/src/lazygit/pkg/integration/components/test.go:230 +0x68
github.com/jesseduffield/lazygit/pkg/integration/tests.GetTests.func2({0x40000c6500, 0x42}, {0x7ff6a22f3b28?, 0x4000171a40?}, {0x40000c17a8?, 0x7ff6a1f73dbc?})
        C:/Users/whitley/src/lazygit/pkg/integration/tests/tests.go:46 +0x208
path/filepath.walk({0x40000c6500, 0x42}, {0x7ff6a22f3b28, 0x4000171a40}, 0x40000c1ab0)
        C:/Program Files/Go/src/path/filepath/path.go:477 +0xc8
path/filepath.walk({0x40000c8840, 0x39}, {0x7ff6a22f3b28, 0x40001719d0}, 0x40000c1ab0)
        C:/Program Files/Go/src/path/filepath/path.go:501 +0x1d4
path/filepath.walk({0x40000c87c0, 0x32}, {0x7ff6a22f3b28, 0x4000171960}, 0x40000c1ab0)
        C:/Program Files/Go/src/path/filepath/path.go:501 +0x1d4
path/filepath.Walk({0x40000c87c0, 0x32}, 0x40000c1ab0)
        C:/Program Files/Go/src/path/filepath/path.go:572 +0x6c
github.com/jesseduffield/lazygit/pkg/integration/tests.GetTests({0x40000a2aa0, 0x1c})
        C:/Users/whitley/src/lazygit/pkg/integration/tests/tests.go:29 +0x174
github.com/jesseduffield/lazygit/pkg/integration/clients.getTestsToRun({0x40000a6060, 0x1, 0x2})
        C:/Users/whitley/src/lazygit/pkg/integration/clients/cli.go:57 +0x30
github.com/jesseduffield/lazygit/pkg/integration/clients.RunCLI({0x40000a6060, 0x1, 0x2}, 0x0, 0x0, 0x0, 0x0)
        C:/Users/whitley/src/lazygit/pkg/integration/clients/cli.go:34 +0x7c
main.main()
        C:/Users/whitley/src/lazygit/cmd/integration_test/main.go:71 +0x484
exit status 2

FWIW this is arm64 Windows 11 Pro running go 1.21.6 for win arm64. Is there a canonical dev setup on Windows I should be using? Right now, I have a minimal setup of just go and git for windows installed.

Unit tests also show some errors:

> go test ./... -short
?       github.com/jesseduffield/lazygit        [no test files]
?       github.com/jesseduffield/lazygit/cmd/integration_test   [no test files]
?       github.com/jesseduffield/lazygit/pkg/app        [no test files]
?       github.com/jesseduffield/lazygit/pkg/app/daemon [no test files]
?       github.com/jesseduffield/lazygit/pkg/app/types  [no test files]
?       github.com/jesseduffield/lazygit/pkg/commands   [no test files]
ok      github.com/jesseduffield/lazygit/pkg/cheatsheet 0.107s
?       github.com/jesseduffield/lazygit/pkg/commands/models    [no test files]
?       github.com/jesseduffield/lazygit/pkg/commands/types/enums       [no test files]
?       github.com/jesseduffield/lazygit/pkg/common     [no test files]
?       github.com/jesseduffield/lazygit/pkg/constants  [no test files]
?       github.com/jesseduffield/lazygit/pkg/fakes      [no test files]
?       github.com/jesseduffield/lazygit/pkg/gui        [no test files]
?       github.com/jesseduffield/lazygit/pkg/env        [no test files]
ok      github.com/jesseduffield/lazygit/pkg/commands/git_commands      0.628s
ok      github.com/jesseduffield/lazygit/pkg/commands/git_config        0.099s
ok      github.com/jesseduffield/lazygit/pkg/commands/hosting_service   0.109s
--- FAIL: TestOSCommandRun (0.00s)
    os_test.go:21:
                Error Trace:    C:\Users\whitley\src\lazygit\pkg\commands\oscommands\os_test.go:21
                                                        C:\Users\whitley\src\lazygit\pkg\commands\oscommands\os_test.go:28
                Error:          Expect "exec: "rmdir": executable file not found in %PATH%" to match "rmdir.*unexisting-folder.*"
                Test:           TestOSCommandRun
FAIL
FAIL    github.com/jesseduffield/lazygit/pkg/commands/oscommands        0.113s
ok      github.com/jesseduffield/lazygit/pkg/commands/patch     0.102s
ok      github.com/jesseduffield/lazygit/pkg/config     0.076s
?       github.com/jesseduffield/lazygit/pkg/gui/context/traits [no test files]
ok      github.com/jesseduffield/lazygit/pkg/gui/context        0.103s
ok      github.com/jesseduffield/lazygit/pkg/gui/controllers    0.104s
ok      github.com/jesseduffield/lazygit/pkg/gui/controllers/helpers    0.110s
?       github.com/jesseduffield/lazygit/pkg/gui/keybindings    [no test files]
?       github.com/jesseduffield/lazygit/pkg/gui/modes/cherrypicking    [no test files]
?       github.com/jesseduffield/lazygit/pkg/gui/modes/filtering        [no test files]
?       github.com/jesseduffield/lazygit/pkg/gui/modes/marked_base_commit       [no test files]
?       github.com/jesseduffield/lazygit/pkg/gui/modes/diffing  [no test files]
ok      github.com/jesseduffield/lazygit/pkg/gui/filetree       0.100s
ok      github.com/jesseduffield/lazygit/pkg/gui/mergeconflicts 0.101s
?       github.com/jesseduffield/lazygit/pkg/gui/popup  [no test files]
ok      github.com/jesseduffield/lazygit/pkg/gui/patch_exploring        0.104s
--- FAIL: TestGetCommitListDisplayStrings (0.00s)
    --- FAIL: TestGetCommitListDisplayStrings/custom_time_format (0.00s)
        commits_test.go:427:
            sha1 2019-12-31 Jesse Duffield    commit1
            sha2 2019-12-20 Jesse Duffield    commit2
        commits_test.go:429:
                Error Trace:    C:\Users\whitley\src\lazygit\pkg\gui\presentation\commits_test.go:429
                Error:          Not equal:
                                expected: "sha1 2:03AM     Jesse Duffield    commit1\nsha2 2019-12-20 Jesse Duffield    commit2"
                                actual  : "sha1 2019-12-31 Jesse Duffield    commit1\nsha2 2019-12-20 Jesse Duffield    commit2"

                                Diff:
                                --- Expected
                                +++ Actual
                                @@ -1,2 +1,2 @@
                                -sha1 2:03AM     Jesse Duffield    commit1
                                +sha1 2019-12-31 Jesse Duffield    commit1
                                 sha2 2019-12-20 Jesse Duffield    commit2
                Test:           TestGetCommitListDisplayStrings/custom_time_format
FAIL
FAIL    github.com/jesseduffield/lazygit/pkg/gui/presentation   0.113s
ok      github.com/jesseduffield/lazygit/pkg/gui/presentation/authors   0.093s
?       github.com/jesseduffield/lazygit/pkg/gui/presentation/icons     [no test files]
ok      github.com/jesseduffield/lazygit/pkg/gui/presentation/graph     0.098s
?       github.com/jesseduffield/lazygit/pkg/gui/status [no test files]
?       github.com/jesseduffield/lazygit/pkg/gui/types  [no test files]
ok      github.com/jesseduffield/lazygit/pkg/gui/services/custom_commands       0.153s
ok      github.com/jesseduffield/lazygit/pkg/gui/style  0.098s
?       github.com/jesseduffield/lazygit/pkg/integration/clients        [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/clients/injector       [no test files]
ok      github.com/jesseduffield/lazygit/pkg/i18n       0.076s
?       github.com/jesseduffield/lazygit/pkg/integration/tests  [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/cherry_pick      [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/commit   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/config   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/conflicts        [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/custom_commands  [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/demo     [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/diff     [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/file     [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/filter_and_search        [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/filter_by_path   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/interactive_rebase       [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/misc     [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/patch_building   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/reflog   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/shared   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/staging  [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/stash    [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/submodule        [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/sync     [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/tag      [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/ui       [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/undo     [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/worktree [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/types  [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/bisect   [no test files]
?       github.com/jesseduffield/lazygit/pkg/integration/tests/branch   [no test files]
ok      github.com/jesseduffield/lazygit/pkg/integration/components     0.105s
?       github.com/jesseduffield/lazygit/pkg/jsonschema [no test files]
?       github.com/jesseduffield/lazygit/pkg/logs       [no test files]
?       github.com/jesseduffield/lazygit/pkg/logs/tail  [no test files]
ok      github.com/jesseduffield/lazygit/pkg/snake      0.066s
?       github.com/jesseduffield/lazygit/pkg/updates    [no test files]
ok      github.com/jesseduffield/lazygit/pkg/tasks      0.884s
ok      github.com/jesseduffield/lazygit/pkg/theme      0.106s
ok      github.com/jesseduffield/lazygit/pkg/utils      0.105s
ok      github.com/jesseduffield/lazygit/pkg/utils/yaml_utils   0.069s
FAIL

@jwhitley
Copy link
Contributor Author

OH, it's dying in TestNameFromFilePath:

func TestNameFromFilePath(path string) string {
	name := strings.Split(path, "integration/tests/")[1]

	return name[:len(name)-len(".go")]
}

Blame says that code is pretty old, so this clearly must have worked. I've tried running from cmd shell and powershell, same failures. Do the integration tests need to run from WSL?

@stefanhaller
Copy link
Collaborator

As far as I know, integration tests have never worked on Windows. It would be great to fix this, but I wouldn't try to do that as part of this PR, which is big enough already.

I can't speak for Jesse, but I understand his request to test this on Windows more like testing it manually to see if everything seems to work. I just a tried a little bit, and starting up lazygit works fine, also in a subfolder of a repo, or in a subfolder of a submodule. I'm not sure what else to test, as I didn't pay much attention to what all the various special situations are that were fixed by this PR. 😅 (And I don't use workspaces.)

@stefanhaller
Copy link
Collaborator

One more thing: I'm a bit unhappy about the commit history (40 commits, yikes!). I find it basically unreadable, but there are also commits in there that don't even compile or fail tests, which is bad for bisecting (in future).

It's probably too late and way too much work to clean it up now, and I don't want to request that; however, I do wonder if it would be better to squash it down to a single commit. (If there's a change that can easily be broken out into a separate commit from there, all the better. I haven't checked.) Let me know what you think.

@jwhitley
Copy link
Contributor Author

As far as I know, integration tests have never worked on Windows. It would be great to fix this, but I wouldn't try to do that as part of this PR, which is big enough already.

I can't speak for Jesse, but I understand his request to test this on Windows more like testing it manually to see if everything seems to work. I just a tried a little bit, and starting up lazygit works fine, also in a subfolder of a repo, or in a subfolder of a submodule. I'm not sure what else to test, as I didn't pay much attention to what all the various special situations are that were fixed by this PR. 😅 (And I don't use workspaces.)

Brilliant, thanks Stefan. I'll kick the tires myself today as well. Also, I'll squash the heck out of this mess. I suspect it'll just be One Big Commit, but if I can sensibly break it up into a set of test-clean commits I will do so.

@jwhitley
Copy link
Contributor Author

OK, One Big Commit has been pushed. I winnowed down the commit message heavily, focusing on the notable functional changes, since there was a lot of implementation/fixup churn. For reference, I made a copy of the original branch at jwhitley/work-tree-from-git-orig.

@stefanhaller
Copy link
Collaborator

Nice. Maybe I'll even review that commit now. 😄 (Not before tomorrow though.)

Meanwhile I made a bit of progress towards getting the integration tests to run on Windows, see #3236. I didn't get far enough to have them run on CI, but I can run them locally at least. They succeed on master, but fail if I cherry-pick your commit on top. I don't have more time to look into this now, but I feel we should figure this out before we merge your PR. Feel free to play with this if you want.

@jwhitley
Copy link
Contributor Author

What are next step(s) to getting this PR to land? On one hand, both Stefan and I have done some light ad-hoc testing. On the other the hopes for some quick progress on Windows tests in #3236 appear to have been dashed. That feels like another extended project, given the current state of things. A lot of what I call "time to first test" infrastructure work.

My thinking is: I'd like to get this PR merged, either now or after some additional to-be-defined due diligence, then focus on getting the Windows unit and integration tests running. At very least, pre-merge and pre-release due diligence would then be able to catch Windows test failures.

@jesseduffield
Copy link
Owner

I'm happy to merge this now, @stefanhaller ?

This changes GetRepoPaths() to pull information from `git rev-parse`
instead of effectively reimplementing git's logic for pathfinding. This
change fixes issues with bare repos, esp. versioned homedir use cases,
by aligning lazygit's path handling to what git itself does.

This change also enables lazygit to run from arbitrary subdirectories of
a repository, including correct handling of symlinks, including "deep"
symlinks into a repo, worktree, a repo's submodules, etc.

Integration tests are now resilient against unintended side effects from
the host's environment variables. Of necessity, $PATH and $TERM are the
only env vars allowed through now.
@stefanhaller
Copy link
Collaborator

Yep, me too. Thanks again for the great work John!

@stefanhaller stefanhaller merged commit b7d4db2 into jesseduffield:master Jan 24, 2024
13 of 14 checks passed
@jesseduffield
Copy link
Owner

Great work on this @jwhitley !

@jwhitley
Copy link
Contributor Author

🎊 awesome, thank you both again for all of your help getting this one landed! 🎊

@jwhitley
Copy link
Contributor Author

I don't believe I'm actually closing this browser tab. 😂

@jwhitley
Copy link
Contributor Author

OH! Don't forget to close out all of the issues covered by this PR. This comment should be the canonical reference, at least of the stuff I found, confirmed fixed, and used as the baseline cases for integration test coverage. See my notes at that comment for details.

renovate bot added a commit to scottames/dots that referenced this pull request Mar 26, 2024
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [aquaproj/aqua-registry](https://github.com/aquaproj/aqua-registry)
| minor | `v4.154.0` -> `v4.155.1` |
| [cli/cli](https://github.com/cli/cli) | minor | `v2.45.0` ->
`v2.46.0` |
| [derailed/k9s](https://github.com/derailed/k9s) | patch | `v0.32.3`
-> `v0.32.4` |
| [eza-community/eza](https://github.com/eza-community/eza) | patch |
`v0.18.7` -> `v0.18.8` |
| [golangci/golangci-lint](https://github.com/golangci/golangci-lint)
| minor | `v1.56.2` -> `v1.57.1` |
|
[gruntwork-io/terragrunt](https://github.com/gruntwork-io/terragrunt)
| patch | `v0.55.16` -> `v0.55.20` |
| [jesseduffield/lazygit](https://github.com/jesseduffield/lazygit) |
minor | `v0.40.2` -> `v0.41.0` |
| [junegunn/fzf](https://github.com/junegunn/fzf) | patch | `0.48.0`
-> `0.48.1` |
| [lsd-rs/lsd](https://github.com/lsd-rs/lsd) | minor | `v1.0.0` ->
`v1.1.2` |
| [mikefarah/yq](https://github.com/mikefarah/yq) | minor | `v4.42.1`
-> `v4.43.1` |
| [simulot/immich-go](https://github.com/simulot/immich-go) | minor |
`0.12.0` -> `0.13.0` |
| [snyk/cli](https://github.com/snyk/cli) | minor | `v1.1284.0` ->
`v1.1286.0` |
| [starship/starship](https://github.com/starship/starship) | minor |
`v1.17.1` -> `v1.18.1` |
| [twpayne/chezmoi](https://github.com/twpayne/chezmoi) | patch |
`v2.47.1` -> `v2.47.2` |
| [weaveworks/eksctl](https://github.com/weaveworks/eksctl) | minor |
`v0.174.0` -> `v0.175.0` |

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Release Notes

<details>
<summary>aquaproj/aqua-registry (aquaproj/aqua-registry)</summary>

###
[`v4.155.1`](https://github.com/aquaproj/aqua-registry/releases/tag/v4.155.1)

[Compare
Source](https://github.com/aquaproj/aqua-registry/compare/v4.155.0...v4.155.1)


[Issues](https://github.com/aquaproj/aqua-registry/issues?q=is%3Aissue+milestone%3Av4.155.0)
| [Pull
Requests](https://github.com/aquaproj/aqua-registry/pulls?q=is%3Apr+milestone%3Av4.155.0)
| https://github.com/aquaproj/aqua-registry/compare/v4.155.0...v4.155.1

##### Others


[#&#8203;21239](https://github.com/aquaproj/aqua-registry/issues/21239)
Rename the package crates.io/shellharden to anordal/shellharden
[@&#8203;hituzi-no-sippo](https://github.com/hituzi-no-sippo)

shellharden started releasing pre-built binaries, so we changed the
package type from `cargo` to `github_release` from shellharden v4.3.1.


[https://github.com/anordal/shellharden/pull/57](https://github.com/anordal/shellharden/pull/57)
https://github.com/anordal/shellharden/releases/tag/v4.3.1

> \[!WARNING]
> Please rename the package `crates.io/shellharden` to
`anordal/shellharden`
>
> ```yaml
> packages:
> - name: anordal/[email protected]
> ```
>
> Note that Renovate will update crates.io/shellharden to
crates.io/[email protected], but it wouldn't work.
> You have to change the version to `v4.3.1`.

###
[`v4.155.0`](https://github.com/aquaproj/aqua-registry/releases/tag/v4.155.0)

[Compare
Source](https://github.com/aquaproj/aqua-registry/compare/v4.154.0...v4.155.0)


[Issues](https://github.com/aquaproj/aqua-registry/issues?q=is%3Aissue+milestone%3Av4.154.0)
| [Pull
Requests](https://github.com/aquaproj/aqua-registry/pulls?q=is%3Apr+milestone%3Av4.154.0)
| https://github.com/aquaproj/aqua-registry/compare/v4.154.0...v4.155.0

#### 🎉 New Packages


[#&#8203;21127](https://github.com/aquaproj/aqua-registry/issues/21127)
[ynqa/jnv](https://github.com/ynqa/jnv): interactive JSON filter using
jq [@&#8203;ponkio-o](https://github.com/ponkio-o)

[#&#8203;21079](https://github.com/aquaproj/aqua-registry/issues/21079)
[zaghaghi/openapi-tui](https://github.com/zaghaghi/openapi-tui):
Terminal UI to list, browse and run APIs defined with openapi spec
[@&#8203;wancup](https://github.com/wancup)

#### Fixes


[#&#8203;21122](https://github.com/aquaproj/aqua-registry/issues/21122)
Update some packages to support Cosign v2

⚠️ To install the following packages, aqua v2.25.1 or later is required.

-   aquaproj/aqua-registry-updater
-   aquaproj/registry-tool
-   argoproj/argo-workflows
-   chainguard-dev/apko
-   chainguard-dev/melange
-   charmbracelet/gum
-   goreleaser/nfpm
-   kubernetes-sigs/zeitgeist
-   lintnet/lintnet
-   suzuki-shunsuke/ci-info
-   suzuki-shunsuke/circleci-config-merge
-   suzuki-shunsuke/cmdx
-   suzuki-shunsuke/ghalint
-   suzuki-shunsuke/ghcp
-   suzuki-shunsuke/github-comment
-   suzuki-shunsuke/mkghtag
-   suzuki-shunsuke/nllint
-   suzuki-shunsuke/pinact
-   suzuki-shunsuke/renovate-issue-action
-   suzuki-shunsuke/tfcmt
-   suzuki-shunsuke/tfprovidercheck
-   terraform-linters/tflint
-   tfmigrator/cli
-   updatecli/updatecli
-   yuyaban/gitlab-comment


[#&#8203;21062](https://github.com/aquaproj/aqua-registry/issues/21062)
[#&#8203;21063](https://github.com/aquaproj/aqua-registry/issues/21063)
[#&#8203;21064](https://github.com/aquaproj/aqua-registry/issues/21064)
[#&#8203;21065](https://github.com/aquaproj/aqua-registry/issues/21065)
[#&#8203;21066](https://github.com/aquaproj/aqua-registry/issues/21066)
Transfer [k0kubun/xremap/\*](https://github.com/k0kubun/xremap) to
[xremap/xremap/\*](https://github.com/xremap/xremap)

The GitHub Repository of the package "k0kubun/xremap/hypr" was
transferred from [k0kubun/xremap](https://github.com/k0kubun/xremap)
to [xremap/xremap](https://github.com/xremap/xremap)

</details>

<details>
<summary>cli/cli (cli/cli)</summary>

### [`v2.46.0`](https://github.com/cli/cli/releases/tag/v2.46.0):
GitHub CLI 2.46.0

[Compare Source](https://github.com/cli/cli/compare/v2.45.0...v2.46.0)

#### What's Changed

- Draft issue IDs are included in `project item-list` output by
[@&#8203;yasunori0418](https://github.com/yasunori0418) in
[https://github.com/cli/cli/pull/8754](https://github.com/cli/cli/pull/8754)
- New `--dry-run` option for `pr create` by
[@&#8203;v1v](https://github.com/v1v) in
[https://github.com/cli/cli/pull/8376](https://github.com/cli/cli/pull/8376)
- Bump go-keyring to fix race condition by
[@&#8203;williammartin](https://github.com/williammartin) in
[https://github.com/cli/cli/pull/8833](https://github.com/cli/cli/pull/8833)
- PR numbers are prefixed with owner/repo for context by
[@&#8203;nobe4](https://github.com/nobe4) in
[https://github.com/cli/cli/pull/8778](https://github.com/cli/cli/pull/8778)
- Extra word removed in `codespaces` code comments by
[@&#8203;cuinix](https://github.com/cuinix) in
[https://github.com/cli/cli/pull/8795](https://github.com/cli/cli/pull/8795)
- Clarified description of the `-u`, `--user` option for `gh auth token`
by [@&#8203;gregsmi](https://github.com/gregsmi) in
[https://github.com/cli/cli/pull/8797](https://github.com/cli/cli/pull/8797)
- Fixed formatting for the description of `release upload` by
[@&#8203;malor](https://github.com/malor) in
[https://github.com/cli/cli/pull/8834](https://github.com/cli/cli/pull/8834)
- Clarified the usage of `auth status` to list all authenticated
accounts by [@&#8203;jsoref](https://github.com/jsoref) in
[https://github.com/cli/cli/pull/8838](https://github.com/cli/cli/pull/8838)
- Document auth switch behavior for two or more accounts by
[@&#8203;williammartin](https://github.com/williammartin) in
[https://github.com/cli/cli/pull/8839](https://github.com/cli/cli/pull/8839)
- Document run watch and view not supporting fine grained PATs by
[@&#8203;williammartin](https://github.com/williammartin) in
[https://github.com/cli/cli/pull/8843](https://github.com/cli/cli/pull/8843)
- build(deps): bump google.golang.org/protobuf from 1.30.0 to 1.33.0 by
[@&#8203;dependabot](https://github.com/dependabot) in
[https://github.com/cli/cli/pull/8811](https://github.com/cli/cli/pull/8811)
- build(deps): bump github.com/cpuguy83/go-md2man/v2 from 2.0.3 to 2.0.4
by [@&#8203;dependabot](https://github.com/dependabot) in
[https://github.com/cli/cli/pull/8844](https://github.com/cli/cli/pull/8844)

#### New Contributors

- [@&#8203;cuinix](https://github.com/cuinix) made their first
contribution in
[https://github.com/cli/cli/pull/8795](https://github.com/cli/cli/pull/8795)
- [@&#8203;gregsmi](https://github.com/gregsmi) made their first
contribution in
[https://github.com/cli/cli/pull/8797](https://github.com/cli/cli/pull/8797)
- [@&#8203;nobe4](https://github.com/nobe4) made their first
contribution in
[https://github.com/cli/cli/pull/8778](https://github.com/cli/cli/pull/8778)
- [@&#8203;malor](https://github.com/malor) made their first
contribution in
[https://github.com/cli/cli/pull/8834](https://github.com/cli/cli/pull/8834)
- [@&#8203;yasunori0418](https://github.com/yasunori0418) made their
first contribution in
[https://github.com/cli/cli/pull/8754](https://github.com/cli/cli/pull/8754)

**Full Changelog**: https://github.com/cli/cli/compare/v2.45.0...v2.46.0

</details>

<details>
<summary>derailed/k9s (derailed/k9s)</summary>

### [`v0.32.4`](https://github.com/derailed/k9s/releases/tag/v0.32.4)

[Compare
Source](https://github.com/derailed/k9s/compare/v0.32.3...v0.32.4)

<img
src="https://raw.githubusercontent.com/derailed/k9s/master/assets/k9s.png"
align="center" width="800" height="auto"/>

### Release v0.32.4
#### Notes

Thank you to all that contributed with flushing out issues and
enhancements for K9s!
I'll try to mark some of these issues as fixed. But if you don't mind
grab the latest rev
and see if we're happier with some of the fixes!
If you've filed an issue please help me verify and close.

Your support, kindness and awesome suggestions to make K9s better are,
as ever, very much noted and appreciated!
Also big thanks to all that have allocated their own time to help others
on both slack and on this repo!!

As you may know, K9s is not pimped out by corps with deep pockets, thus
if you feel K9s is helping your Kubernetes journey,
please consider joining our [sponsorship
program](https://github.com/sponsors/derailed) and/or make some noise
on social! [@&#8203;kitesurfer](https://twitter.com/kitesurfer)

On Slack? Please join us
[K9slackers](https://join.slack.com/t/k9sers/shared_invite/enQtOTA5MDEyNzI5MTU0LWQ1ZGI3MzliYzZhZWEyNzYxYzA3NjE0YTk1YmFmNzViZjIyNzhkZGI0MmJjYzhlNjdlMGJhYzE2ZGU1NjkyNTM)

#### Maintenance Release!

***

#### ♫ Sounds Behind The Release ♭

Thinking of all you at KubeCon Paris!!
May I suggest a nice glass of `cold Merlote` or other fine grape juices
from my country?

- [Le Gorille - George
Brassens](https://www.youtube.com/watch?v=KVfwvk_yVyA)
- [Les Funerailles D'antan (Love this guy!) - George
Brassens](https://www.youtube.com/watch?v=bwb5k4k2EMc)
- [Poinconneur Des Lilas - Serge
Gainsbourg](https://www.youtube.com/watch?v=eWkWCFzkOvU)
- [Mon Legionaire (Yup! same guy??) - Serge
Gainsbourg](https://www.youtube.com/watch?v=gl8gopryqWI)
- [Les Cornichons - Nino
Ferrer](https://www.youtube.com/watch?v=N7JSW4NhM8I)
- [Paris s'eveille - Jacques
Dutronc](https://www.youtube.com/watch?v=3WcCg6rm3uM)

***

#### Videos Are In The Can!

Please dial [K9s
Channel](https://www.youtube.com/channel/UC897uwPygni4QIjkPCpgjmw) for
up coming content...

-   [K9s v0.31.0 Configs+Sneak peek](https://youtu.be/X3444KfjguE)
-   [K9s v0.30.0 Sneak peek](https://youtu.be/mVBc1XneRJ4)
-   [Vulnerability Scans](https://youtu.be/ULkl0MsaidU)

***

#### Resolved Issues

- [#&#8203;2608](https://github.com/derailed/k9s/issues/2608) Make the
sanitize feature easier to use
- [#&#8203;2605](https://github.com/derailed/k9s/issues/2605) Built-in
shortcuts being overridden by plugins result in excessive logging
- [#&#8203;2604](https://github.com/derailed/k9s/issues/2604) Ability
to mark a plugin as Dangerous/destructive
- [#&#8203;2592](https://github.com/derailed/k9s/issues/2592) "list
access denied" when switching contexts within k9s since 0.32.0

***

#### Contributed PRs

Please be sure to give `Big Thanks!` and `ATTA Girls/Boys!` to all the
fine contributors for making K9s better for all of us!!

- [#&#8203;2621](https://github.com/derailed/k9s/pull/2621) Fix snap
build

***

<img
src="https://raw.githubusercontent.com/derailed/k9s/master/assets/imhotep_logo.png"
width="32" height="auto"/> © 2024 Imhotep Software LLC. All materials
licensed under [Apache v2.0](http://www.apache.org/licenses/LICENSE-2.0)

</details>

<details>
<summary>eza-community/eza (eza-community/eza)</summary>

###
[`v0.18.8`](https://github.com/eza-community/eza/releases/tag/v0.18.8):
eza v0.18.8

[Compare
Source](https://github.com/eza-community/eza/compare/v0.18.7...v0.18.8)

### Changelog

#### \[0.18.8] - 2024-03-21

##### Bug Fixes

-   Avoid deprecation warnings
-   Rustfmt issues

##### Features

-   Add fennel lang icon and associations

##### Miscellaneous Tasks

-   Release eza v0.18.8

### Checksums

#### sha256sum

80565916de55b23c3cabb363ba1cb7f323f99b158e75b6c029a64108de7bdad9
./target/bin-0.18.8/eza_aarch64-unknown-linux-gnu.tar.gz
d3532278f5eae1c1dd57bcc9373f05b49f40ffac880d5c4efb67ac5d93cdf0ea
./target/bin-0.18.8/eza_aarch64-unknown-linux-gnu.zip
2c1722afbb0f90e40047cfffa93f04fb9b89633402236fb75119c9105265271f
./target/bin-0.18.8/eza_arm-unknown-linux-gnueabihf.tar.gz
a832c4694228780f43f467e2f0536bd4a8969a455edbb872eb8b4614ebd157e0
./target/bin-0.18.8/eza_arm-unknown-linux-gnueabihf.zip
39cc743e9293a5e269b2b2baf167f4f868f682143dc8b1f87efd64848bb3bca4
./target/bin-0.18.8/eza.exe_x86_64-pc-windows-gnu.tar.gz
9b331b2eee259a9afbffd39e5018735651f8053c5429714cdc46a02f571463e7
./target/bin-0.18.8/eza.exe_x86_64-pc-windows-gnu.zip
2e12d0b714aa011d23abb72459a2478eb9e369ac564a9a7e39ba6ec7ef775ad4
./target/bin-0.18.8/eza_x86_64-unknown-linux-gnu.tar.gz
e3c9c3535732cecad5eb9d786e1f7a7c66aa28d42a3516046e5b1cf7f3799920
./target/bin-0.18.8/eza_x86_64-unknown-linux-gnu.zip
2fc6c3ead5c8bc596643597737ba596aee2f61772792927e4e9e602525a6ae81
./target/bin-0.18.8/eza_x86_64-unknown-linux-musl.tar.gz
543f69f52165f654c5ab869319663d7f4ebdc95b7fc9c23be003ca551aec5dc3
./target/bin-0.18.8/eza_x86_64-unknown-linux-musl.zip

#### md5sum

f3dece765bb95c732bce9406c1eb825a
./target/bin-0.18.8/eza_aarch64-unknown-linux-gnu.tar.gz
b655997af2b0df307abd3a126e48fc3d
./target/bin-0.18.8/eza_aarch64-unknown-linux-gnu.zip
9cd1ae35fd90e4341cf8ed1b4a3d6cd9
./target/bin-0.18.8/eza_arm-unknown-linux-gnueabihf.tar.gz
e9cd1a917b39827fc159c100faaf28b9
./target/bin-0.18.8/eza_arm-unknown-linux-gnueabihf.zip
9f02446483003c219eecc1dc15273956
./target/bin-0.18.8/eza.exe_x86_64-pc-windows-gnu.tar.gz
db239fa66fde9800770384831e3a86fa
./target/bin-0.18.8/eza.exe_x86_64-pc-windows-gnu.zip
5722d3f4e4f2848d770713341c7c4bfd
./target/bin-0.18.8/eza_x86_64-unknown-linux-gnu.tar.gz
c9f5ece20dc527fd4ecf4f77bbf70b56
./target/bin-0.18.8/eza_x86_64-unknown-linux-gnu.zip
0826369c7f0ab3b17c4275f98ff1ab70
./target/bin-0.18.8/eza_x86_64-unknown-linux-musl.tar.gz
3c3633a6c54d32ee9f04277f4b103edc
./target/bin-0.18.8/eza_x86_64-unknown-linux-musl.zip

#### blake3sum

0c7fc89dd1cf514e62e644e8ff8dab8759d6bd42f364f2768c41df92ec9e9dfc
./target/bin-0.18.8/eza_aarch64-unknown-linux-gnu.tar.gz
540def87f4f455fcd6067648f05498db775c6c03f291088d03f1dc4cc8cf68e7
./target/bin-0.18.8/eza_aarch64-unknown-linux-gnu.zip
1980d8004ad1f9b0291381c4d57db64fc8ebcf1c0961a8ac3c05c3697d7dfaf3
./target/bin-0.18.8/eza_arm-unknown-linux-gnueabihf.tar.gz
9a80d9f0cfc83521d119778b52b55dce4b33f28b02624297c712efd3ade53f19
./target/bin-0.18.8/eza_arm-unknown-linux-gnueabihf.zip
5d97ba1a2eaccc814aec982922f89ee218521b343b5f3ad6900596ad9574bfa3
./target/bin-0.18.8/eza.exe_x86_64-pc-windows-gnu.tar.gz
2d274f097297ff222dc7756903dfb73fdc744051c75b815d2eea2e08ee0f4418
./target/bin-0.18.8/eza.exe_x86_64-pc-windows-gnu.zip
04ca09128611f9719ac0a7c387282049489243bbe74be8de797d845ec380b9ee
./target/bin-0.18.8/eza_x86_64-unknown-linux-gnu.tar.gz
3e58bf50b39c1b20801f5282b612103b07b12089d2a24f3dcec9882ac8482c8c
./target/bin-0.18.8/eza_x86_64-unknown-linux-gnu.zip
1df711c44e08cc08fc26753f5c50f9de244fdbd7e2f8cc3961d82f101d775154
./target/bin-0.18.8/eza_x86_64-unknown-linux-musl.tar.gz
9d71a5afbc797ca63eecf254fc4971c2a1dd188ce28c8cb4a10cf1a273d747d5
./target/bin-0.18.8/eza_x86_64-unknown-linux-musl.zip

</details>

<details>
<summary>golangci/golangci-lint (golangci/golangci-lint)</summary>

###
[`v1.57.1`](https://github.com/golangci/golangci-lint/releases/tag/v1.57.1)

[Compare
Source](https://github.com/golangci/golangci-lint/compare/v1.57.0...v1.57.1)

#### Changelog

-
[`87b6bf1`](https://github.com/golangci/golangci-lint/commit/87b6bf17)
build(deps): bump github.com/golangci/plugin-module-register from 0.1.0
to 0.1.1
([#&#8203;4549](https://github.com/golangci/golangci-lint/issues/4549))
-
[`921d535`](https://github.com/golangci/golangci-lint/commit/921d5357)
build(deps): bump github.com/pelletier/go-toml/v2 from 2.1.1 to 2.2.0
([#&#8203;4548](https://github.com/golangci/golangci-lint/issues/4548))
-
[`cd890db`](https://github.com/golangci/golangci-lint/commit/cd890db2)
fix: filter invalid issues before other processors
([#&#8203;4552](https://github.com/golangci/golangci-lint/issues/4552))

###
[`v1.57.0`](https://github.com/golangci/golangci-lint/compare/v1.56.2...v1.57.0)

[Compare
Source](https://github.com/golangci/golangci-lint/compare/v1.56.2...v1.57.0)

</details>

<details>
<summary>gruntwork-io/terragrunt (gruntwork-io/terragrunt)</summary>

###
[`v0.55.20`](https://github.com/gruntwork-io/terragrunt/compare/v0.55.19...v0.55.20)

[Compare
Source](https://github.com/gruntwork-io/terragrunt/compare/v0.55.19...v0.55.20)

###
[`v0.55.19`](https://github.com/gruntwork-io/terragrunt/releases/tag/v0.55.19)

[Compare
Source](https://github.com/gruntwork-io/terragrunt/compare/v0.55.18...v0.55.19)

#### Updated CLI args, config attributes and blocks

-   `scaffold`

#### Description

-   Fix grammar in feature text
-   Fix URL handling in the `scaffold` command
-   Updated gon version to 0.2.5

#### Related links

-
[https://github.com/gruntwork-io/terragrunt/pull/3010](https://github.com/gruntwork-io/terragrunt/pull/3010)
-
[https://github.com/gruntwork-io/terragrunt/pull/3005](https://github.com/gruntwork-io/terragrunt/pull/3005)

**Full Changelog**:
https://github.com/gruntwork-io/terragrunt/compare/v0.55.18...v0.55.19

###
[`v0.55.18`](https://github.com/gruntwork-io/terragrunt/releases/tag/v0.55.18)

[Compare
Source](https://github.com/gruntwork-io/terragrunt/compare/v0.55.17...v0.55.18)

#### Description

-   Updated github.com/cloudflare/circl from 1.3.3 to 1.3.7
-   Updated github.com/go-jose/go-jose/v3 from 3.0.0 to 3.0.3
-   Updated google.golang.org/protobuf from 1.32.0 to 1.33.0
-   Updated nokogiri to 1.16.3
-   Updates mini_portile2 from 2.4.0 to 2.8.5

#### Related links

-
[https://github.com/gruntwork-io/terragrunt/pull/2995](https://github.com/gruntwork-io/terragrunt/pull/2995)
-
[https://github.com/gruntwork-io/terragrunt/pull/2996](https://github.com/gruntwork-io/terragrunt/pull/2996)
-
[https://github.com/gruntwork-io/terragrunt/pull/2929](https://github.com/gruntwork-io/terragrunt/pull/2929)
-
[https://github.com/gruntwork-io/terragrunt/pull/3000](https://github.com/gruntwork-io/terragrunt/pull/3000)
-
[https://github.com/gruntwork-io/terragrunt/pull/3009](https://github.com/gruntwork-io/terragrunt/pull/3009)

###
[`v0.55.17`](https://github.com/gruntwork-io/terragrunt/releases/tag/v0.55.17)

[Compare
Source](https://github.com/gruntwork-io/terragrunt/compare/v0.55.16...v0.55.17)

#### Updated CLI args, config attributes and blocks

-   `terraform`

#### Description

-   Added support for OpenTofu registry for shorthand TFR modules.

#### Related links

-
[https://github.com/gruntwork-io/terragrunt/pull/2961](https://github.com/gruntwork-io/terragrunt/pull/2961)

</details>

<details>
<summary>jesseduffield/lazygit (jesseduffield/lazygit)</summary>

###
[`v0.41.0`](https://github.com/jesseduffield/lazygit/releases/tag/v0.41.0)

[Compare
Source](https://github.com/jesseduffield/lazygit/compare/v0.40.2...pre-0.41)

Hold on tight because this is a HUGE release! This release includes a
whopping 595 commits from a period of over 7 months, from 40 different
contributors. Thanks to everybody who made this possible, and apologies
for taking so long to actually release it: we'll be more frequent in
future!

Special thanks to Stefan Haller who is behind many of this release's
changes and who has been critical in getting this release across the
line.

I've made a video running through the big changes here:

[<img
src="https://github.com/jesseduffield/lazygit/assets/8456633/f9b47c5e-f8b2-4b41-8f51-bf06b01046e2">](https://youtu.be/\_REmkoIyPW0)

#### What's Changed

Here's some highlighted features:

##### Range select


![range-select](https://github.com/jesseduffield/lazygit/blob/assets/demo/interactive_rebase-compressed.gif?raw=true)

You can now press 'v' to toggle range select in any list view, just like
you already could in the staging view. You can also press shift+up/down
to select a range. You can use range select to:

-   stage/discard a range of files
- select multiple commits to fixup/squash/move outside an interactive
rebase
- select multiple commits to mark as fixup/squash/etc within an
interactive rebase
- select multiple commit files to discard or add to a custom patch
(courtesy of [@&#8203;afhoffman](https://github.com/afhoffman))
-   select multiple commits to cherry-pick

I have been waiting for this feature for a very long time and it's
already made me way more productive. If I need to squash a range of
commits I can now easily do it directly rather than needing to squash
them one-by-one, or needing to manually start an interactive rebase
first. Likewise, it's much easier to select a range of files and stage
them than stage them one-by-one.

This is a **Breaking change**: Unfortunately, the 'v' key clashes with
the existing key for pasting commits (cherry-pick), so we've replaced
that with shift+V and changed the commit copy key to shift+C. If you
want the old keybindings back, you can do that like so:

```yml
keybinding:
  universal:
      toggleRangeSelect: <something other than v>
    commits:
      cherryPickCopy: 'c'
      pasteCommits: 'v'
```

##### Auto-wrap in commit editor

The commit editor now automatically hard-wraps your content by default,
so you no longer need to hit the enter key yourself when you approach
the margin. You can disable/configure this in your config:

```yml
git:
  commit:
    autoWrapCommitMessage: true
    autoWrapWidth: 72
```

Thanks to [@&#8203;stefanhaller](https://github.com/stefanhaller) for
this feature.

##### Easier remote branch checkout

Now when you go to checkout a remote branch, either via the `c`
keybinding in the branches view or by pressing `space` on a remote
branch, you'll be given the choice to checkout as a local branch or as a
detached head (previously it would just check it out as a detached head
which typically isn't what you want). This is a **Breaking change** in
terms of muscle memory.

Thanks to [@&#8203;stefanhaller](https://github.com/stefanhaller) for
this feature.

##### Easier start interactive rebase

Previously, to start an interactive rebase, you would need to navigate
to a base commit and press `e` on it. Now you can simply press `i` and
regardless of which commit is selected, an interactive rebase will begin
that includes all the commits on your branch (or if there are merge
commits: all the commits up to first merge commit).

The above demo for range select showcases this.

##### Easier squashing of `fixup!` commits

In a similar vein to the above section, now when you press `shift+S`,
you're given the choice of squashing all commits above the selected
commit and squashing all commits on the branch, which is what you
typically want. This is a **Breaking change** in terms of muscle memory.

Thanks to [@&#8203;stefanhaller](https://github.com/stefanhaller) for
this feature.

##### View divergence from upstream branch

If you press `u` on a local branch a menu appears which shows options
relating to the branch's upstream. Now, the first option in that menu
allows you to view the divergence from the upstream which shows commits
to pull and commits to push

Thanks to [@&#8203;stefanhaller](https://github.com/stefanhaller) for
this feature.

##### Find appropriate commit for fixup/amend

This one is some serious voodoo: if somebody suggests changes in a PR
review, you'll often apply the changes, then go hunting for the
appropriate commit to fixup/amend. Now, from the files view you can
press `ctrl+f` and if Lazygit can identify an appropriate commit with
certainty, it will select that commit for you. Pretty cool!

We've made the algorithm very strict so that you can always trust the
result, but this means in circumstances where we can't know for sure
which commit is appropriate (such as when your changes only include
added lines), it's left to you to manually find the commit. We're keen
to get lots of feedback on this feature to see where the sweet spot is.

For more info see [the
docs](https://github.com/jesseduffield/lazygit/blob/master/docs/Fixup_Commits.md#finding-the-commit-to-create-a-fixup-for)

Thanks to [@&#8203;stefanhaller](https://github.com/stefanhaller) for
this feature.

##### Delete remote branches/tags

Now when you press `d` on a local branch, remote branch, or tag, you're
given the option to delete that branch/tag in the remote.

Thanks to [@&#8203;AzraelSec](https://github.com/AzraelSec) for this
feature.

##### Add co-author to commit

When you press `a` on a commit an option now appears to add a co-author
(something GitHub can read).

Thanks to [@&#8203;omaussa](https://github.com/omaussa) for this
feature.

##### Filter commits by author

You can now filter commits by author via pressing `ctrl+s` in the
commits view and selecting the option to filter by author.

Thanks to [@&#8203;Part22](https://github.com/Part22) for this
feature.

##### Change branch sort order

You can now change branch sort order by pressing `s` in the branches
view (and remote branches view). By default local branches are sorted by
'recency' meaning how recently they were checked out, but you can now
sort by head commit date and alphabetically.

Thanks to [@&#8203;hosaka](https://github.com/hosaka) for this
feature.

##### Better bare repo support

We have fixed a bunch of bugs relating to bare repos so if you had
issues with them in the past it should work fine now.

Thanks to [@&#8203;jwhitley](https://github.com/jwhitley) for this
feature.

##### Miscelleneous UI changes

- Unstaged files are now shown in white, not red, which is easier on the
eyes
-   Scrollbars are thinner (and, thus, cooler)
- Keybindings menu now has section headers
([@&#8203;stefanhaller](https://github.com/stefanhaller))
- Error toasts now appear for some errors (less intrusive than popups)
([@&#8203;stefanhaller](https://github.com/stefanhaller))
- Search history is now retained
([@&#8203;karimkhaleel](https://github.com/karimkhaleel))
- Git log is shown by default
([@&#8203;stefanhaller](https://github.com/stefanhaller))

##### More Breaking Changes 💥

- When you press 'g' to bring up the git reset menu, the 'mixed' option
is now the first and default, rather than 'soft'. This is because
'mixed' is the most commonly used option.
- Push/pull/fetch loading statuses are now shown against the branch
rather than in a popup. This allows you to e.g. fetch multiple branches
in parallel and see the status for each branch.
- The git log graph in the commits view is now always shown by default
(previously it was only shown when the view was maximised). If you find
this too noisy, you can change it back via `ctrl+L` -> 'Show git graph'
-> 'when maximised'
- Filtering (e.g. when pressing '/') is less fuzzy by default; it only
matches substrings now. Multiple substrings can be matched by separating
them with spaces. If you want to revert to the old behavior, set the
following in your config:

```yml
gui:
  filterMode: 'fuzzy'
```

#### What's Changed

##### All Enhancements 🔥

- Add range selection ability on list contexts by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3207](https://github.com/jesseduffield/lazygit/pull/3207)
- Allow deleting remote tags/branches from local tag/branch views by
[@&#8203;AzraelSec](https://github.com/AzraelSec) in
[https://github.com/jesseduffield/lazygit/pull/2738](https://github.com/jesseduffield/lazygit/pull/2738)
- Add command to show divergence from upstream by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2871](https://github.com/jesseduffield/lazygit/pull/2871)
- Add 'Quick start interactive rebase' action by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3213](https://github.com/jesseduffield/lazygit/pull/3213)
- Add command to open git difftool by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3156](https://github.com/jesseduffield/lazygit/pull/3156)
- Support editing files in existing neovim instance by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/2916](https://github.com/jesseduffield/lazygit/pull/2916)
- Show commit mark before showing extra info by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/2928](https://github.com/jesseduffield/lazygit/pull/2928)
- Jump to middle of the view when selection leaves the visible area by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2915](https://github.com/jesseduffield/lazygit/pull/2915)
- Add emacs-keybinds for word navigation by
[@&#8203;horriblename](https://github.com/horriblename) in
[https://github.com/jesseduffield/lazygit/pull/2935](https://github.com/jesseduffield/lazygit/pull/2935)
- Add `gui.scrollOffBehavior` config for scrolling list views by
half-pages by [@&#8203;stefanhaller](https://github.com/stefanhaller)
in
[https://github.com/jesseduffield/lazygit/pull/2939](https://github.com/jesseduffield/lazygit/pull/2939)
- Switch to editor from commit message panel by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2881](https://github.com/jesseduffield/lazygit/pull/2881)
- Select same commit again after pressing "e" to edit a commit by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2954](https://github.com/jesseduffield/lazygit/pull/2954)
- Support custom keybindings for confirm discard by
[@&#8203;mskelton](https://github.com/mskelton) in
[https://github.com/jesseduffield/lazygit/pull/2960](https://github.com/jesseduffield/lazygit/pull/2960)
- Allow adding a port to webDomain part of services config by
[@&#8203;raidora](https://github.com/raidora) in
[https://github.com/jesseduffield/lazygit/pull/2908](https://github.com/jesseduffield/lazygit/pull/2908)
- Add icons for files with .mdx and .svelte file extensions by
[@&#8203;hrstmr](https://github.com/hrstmr) in
[https://github.com/jesseduffield/lazygit/pull/2889](https://github.com/jesseduffield/lazygit/pull/2889)
- Section headers in keybindings menu by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2911](https://github.com/jesseduffield/lazygit/pull/2911)
- Check for staged files for "Amend commit" and "Create fixup commit" by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2970](https://github.com/jesseduffield/lazygit/pull/2970)
- Add support for external diff commands (e.g. difftastic) by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2868](https://github.com/jesseduffield/lazygit/pull/2868)
- Save diff context size in state.yml instead of config.yml by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2969](https://github.com/jesseduffield/lazygit/pull/2969)
- Support to reset the current branch to a selected branch upstream by
[@&#8203;AzraelSec](https://github.com/AzraelSec) in
[https://github.com/jesseduffield/lazygit/pull/2940](https://github.com/jesseduffield/lazygit/pull/2940)
- Replace whitespace with '-' when renaming a branch by
[@&#8203;calthejuggler](https://github.com/calthejuggler) in
[https://github.com/jesseduffield/lazygit/pull/2990](https://github.com/jesseduffield/lazygit/pull/2990)
- Add jump-to-panel label config setting by
[@&#8203;MariaSolOs](https://github.com/MariaSolOs) in
[https://github.com/jesseduffield/lazygit/pull/2993](https://github.com/jesseduffield/lazygit/pull/2993)
- Add co-author to commits by
[@&#8203;omaussa](https://github.com/omaussa) in
[https://github.com/jesseduffield/lazygit/pull/2912](https://github.com/jesseduffield/lazygit/pull/2912)
- Change the default of the "gui.borders" config to "rounded" by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2998](https://github.com/jesseduffield/lazygit/pull/2998)
- Add a DisabledReason mechanism for menu items and keybindings by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2992](https://github.com/jesseduffield/lazygit/pull/2992)
- Allow cherry-picking commits during a rebase by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3013](https://github.com/jesseduffield/lazygit/pull/3013)
- Add history for search view by
[@&#8203;karimkhaleel](https://github.com/karimkhaleel) in
[https://github.com/jesseduffield/lazygit/pull/2877](https://github.com/jesseduffield/lazygit/pull/2877)
- Replace loader panels with waiting status (pull/push/fetch) by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2973](https://github.com/jesseduffield/lazygit/pull/2973)
- Add menu to rebase onto selected branch remote upstream by
[@&#8203;AzraelSec](https://github.com/AzraelSec) in
[https://github.com/jesseduffield/lazygit/pull/3020](https://github.com/jesseduffield/lazygit/pull/3020)
- Add ability to force portrait mode by
[@&#8203;ldelossa](https://github.com/ldelossa) in
[https://github.com/jesseduffield/lazygit/pull/3037](https://github.com/jesseduffield/lazygit/pull/3037)
- Add Micro editor preset by [@&#8203;kytta](https://github.com/kytta)
in
[https://github.com/jesseduffield/lazygit/pull/3049](https://github.com/jesseduffield/lazygit/pull/3049)
- Show sync status in branches list by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3021](https://github.com/jesseduffield/lazygit/pull/3021)
- Add 'lvim' editor preset for lunarvim by
[@&#8203;zottelsheep](https://github.com/zottelsheep) in
[https://github.com/jesseduffield/lazygit/pull/3074](https://github.com/jesseduffield/lazygit/pull/3074)
- Truncate branch names to make branch status always visible by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3075](https://github.com/jesseduffield/lazygit/pull/3075)
- Color file icons by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3080](https://github.com/jesseduffield/lazygit/pull/3080)
- Add UserConfig jsonschema generation script by
[@&#8203;karimkhaleel](https://github.com/karimkhaleel) in
[https://github.com/jesseduffield/lazygit/pull/3039](https://github.com/jesseduffield/lazygit/pull/3039)
- Add a copy-to-clipboard menu to the file view (with `diff` copy
options) by [@&#8203;AzraelSec](https://github.com/AzraelSec) in
[https://github.com/jesseduffield/lazygit/pull/3104](https://github.com/jesseduffield/lazygit/pull/3104)
- Fix bottom line alignment by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3076](https://github.com/jesseduffield/lazygit/pull/3076)
- Make move up/down blocking by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2966](https://github.com/jesseduffield/lazygit/pull/2966)
- Add remote branch sorting menu by
[@&#8203;hosaka](https://github.com/hosaka) in
[https://github.com/jesseduffield/lazygit/pull/3171](https://github.com/jesseduffield/lazygit/pull/3171)
- Add age to stash entries by
[@&#8203;AzraelSec](https://github.com/AzraelSec) in
[https://github.com/jesseduffield/lazygit/pull/3174](https://github.com/jesseduffield/lazygit/pull/3174)
- Add local branch sorting menu by
[@&#8203;hosaka](https://github.com/hosaka) in
[https://github.com/jesseduffield/lazygit/pull/3182](https://github.com/jesseduffield/lazygit/pull/3182)
- Show a friendly error message when starting lazygit from a
non-existent cwd by
[@&#8203;simonwhitaker](https://github.com/simonwhitaker) in
[https://github.com/jesseduffield/lazygit/pull/3192](https://github.com/jesseduffield/lazygit/pull/3192)
- Replace copy commit SHA with copy commit subject on the y s keybind in
the commits view by
[@&#8203;karimkhaleel](https://github.com/karimkhaleel) in
[https://github.com/jesseduffield/lazygit/pull/3188](https://github.com/jesseduffield/lazygit/pull/3188)
- Add config setting for splitting window vertically in half screen mode
by [@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3133](https://github.com/jesseduffield/lazygit/pull/3133)
- Add command to find base commit for creating a fixup by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3105](https://github.com/jesseduffield/lazygit/pull/3105)
- Show Toast instead of error panel when invoking a disabled command by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3180](https://github.com/jesseduffield/lazygit/pull/3180)
- Show file names in default colour by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3081](https://github.com/jesseduffield/lazygit/pull/3081)
- Add config setting to suppress showing file icons by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3216](https://github.com/jesseduffield/lazygit/pull/3216)
- Support range select for rebase actions by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3232](https://github.com/jesseduffield/lazygit/pull/3232)
- Make range selections created with the mouse non-sticky by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3234](https://github.com/jesseduffield/lazygit/pull/3234)
- Support range select for staging/discarding files by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3248](https://github.com/jesseduffield/lazygit/pull/3248)
- Inline status for fetching remotes by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3238](https://github.com/jesseduffield/lazygit/pull/3238)
- Add shortcuts for filtering files by status by
[@&#8203;mark2185](https://github.com/mark2185) in
[https://github.com/jesseduffield/lazygit/pull/3137](https://github.com/jesseduffield/lazygit/pull/3137)
- Keep same selection range when quick-starting an interactive rebase by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3247](https://github.com/jesseduffield/lazygit/pull/3247)
- Add loads of tooltips by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3269](https://github.com/jesseduffield/lazygit/pull/3269)
- Show better keybinding suggestions by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3203](https://github.com/jesseduffield/lazygit/pull/3203)
- Support selecting file range in patch builder by
[@&#8203;afhoffman](https://github.com/afhoffman) in
[https://github.com/jesseduffield/lazygit/pull/3259](https://github.com/jesseduffield/lazygit/pull/3259)
- Add command to squash all fixups in the current branch by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3274](https://github.com/jesseduffield/lazygit/pull/3274)
- Use slimmer scrollbars by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3283](https://github.com/jesseduffield/lazygit/pull/3283)
- Clear cherry-picked commits after pasting by
[@&#8203;molejnik88](https://github.com/molejnik88) in
[https://github.com/jesseduffield/lazygit/pull/3240](https://github.com/jesseduffield/lazygit/pull/3240)
- Change default of git.log.showGraph to 'always' by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3314](https://github.com/jesseduffield/lazygit/pull/3314)
- Support range select removing files from a commit by
[@&#8203;afhoffman](https://github.com/afhoffman) in
[https://github.com/jesseduffield/lazygit/pull/3276](https://github.com/jesseduffield/lazygit/pull/3276)
- Migrate git.log.showGraph and git.log.order to app state by
[@&#8203;hosaka](https://github.com/hosaka) in
[https://github.com/jesseduffield/lazygit/pull/3197](https://github.com/jesseduffield/lazygit/pull/3197)
- Change "git reset" default to --mixed by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3264](https://github.com/jesseduffield/lazygit/pull/3264)
- Add author filtering to commit view by
[@&#8203;part22](https://github.com/part22) in
[https://github.com/jesseduffield/lazygit/pull/3302](https://github.com/jesseduffield/lazygit/pull/3302)
- Provide two helix presets, one for "helix" and one for "hx" by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3346](https://github.com/jesseduffield/lazygit/pull/3346)
- Don't show branch head on rebase todos if the rebase.updateRefs config
is on by [@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3340](https://github.com/jesseduffield/lazygit/pull/3340)
- Show all submodules recursively by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3341](https://github.com/jesseduffield/lazygit/pull/3341)
- Support setting a range of commits to "edit" outside of a rebase by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3370](https://github.com/jesseduffield/lazygit/pull/3370)
- Adjust selection after squashing fixups by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3338](https://github.com/jesseduffield/lazygit/pull/3338)
- Auto-wrap commit message while typing by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3173](https://github.com/jesseduffield/lazygit/pull/3173)
- Add Co-Author support to new commits by
[@&#8203;2KAbhishek](https://github.com/2KAbhishek) in
[https://github.com/jesseduffield/lazygit/pull/3097](https://github.com/jesseduffield/lazygit/pull/3097)
- Show "breaking changes" message at startup by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3377](https://github.com/jesseduffield/lazygit/pull/3377)
- Allow moving and deleting update-ref todos by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3391](https://github.com/jesseduffield/lazygit/pull/3391)
- When checking out a remote branch by name, ask the user how by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3388](https://github.com/jesseduffield/lazygit/pull/3388)
- Use substring filtering instead of fuzzy filtering by default by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3376](https://github.com/jesseduffield/lazygit/pull/3376)
- Always prompt to return from subprocess if there was an error by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3410](https://github.com/jesseduffield/lazygit/pull/3410)
- When adding a new remote, select it and fetch it by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3401](https://github.com/jesseduffield/lazygit/pull/3401)
- Support editing multiple files at once using range selection by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3407](https://github.com/jesseduffield/lazygit/pull/3407)
- Make it easy to create "amend!" commits by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3409](https://github.com/jesseduffield/lazygit/pull/3409)
- Add config to truncate commit hashes when copying them to the
clipboard by [@&#8203;stefanhaller](https://github.com/stefanhaller)
in
[https://github.com/jesseduffield/lazygit/pull/3402](https://github.com/jesseduffield/lazygit/pull/3402)

##### Fixes 🔧

- Fix issue where explosion effect was out-of-view by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/2909](https://github.com/jesseduffield/lazygit/pull/2909)
- Show dialogue when attempting to open info link fails by
[@&#8203;simonwhitaker](https://github.com/simonwhitaker) in
[https://github.com/jesseduffield/lazygit/pull/2899](https://github.com/jesseduffield/lazygit/pull/2899)
- Fix jumping to the correct line from the staging view by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2919](https://github.com/jesseduffield/lazygit/pull/2919)
- Fix sha colors when rebasing by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2946](https://github.com/jesseduffield/lazygit/pull/2946)
- Fix the commit graph display after selection jumps in commits view by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2943](https://github.com/jesseduffield/lazygit/pull/2943)
- Handle trailing slash in worktree path by
[@&#8203;Krismix1](https://github.com/Krismix1) in
[https://github.com/jesseduffield/lazygit/pull/2947](https://github.com/jesseduffield/lazygit/pull/2947)
- Fix escape not cancelling filter mode, but closing the menu instead by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2977](https://github.com/jesseduffield/lazygit/pull/2977)
- Use `Error` method to handle commits url copy from unknown service by
[@&#8203;AzraelSec](https://github.com/AzraelSec) in
[https://github.com/jesseduffield/lazygit/pull/3007](https://github.com/jesseduffield/lazygit/pull/3007)
- Hide waiting status during credentials prompt by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3016](https://github.com/jesseduffield/lazygit/pull/3016)
- Use upstream branch when opening pull requests by
[@&#8203;mark2185](https://github.com/mark2185) in
[https://github.com/jesseduffield/lazygit/pull/2693](https://github.com/jesseduffield/lazygit/pull/2693)
- Fix issue where active search inappropriately changed selected line by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3022](https://github.com/jesseduffield/lazygit/pull/3022)
- Respect $GIT_WORK_TREE and $GIT_DIR env vars (fix
[#&#8203;3010](https://github.com/jesseduffield/lazygit/issues/3010)).
by [@&#8203;intrntbrn](https://github.com/intrntbrn) in
[https://github.com/jesseduffield/lazygit/pull/3024](https://github.com/jesseduffield/lazygit/pull/3024)
- Fix crash when trying to filter the list of remotes by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3059](https://github.com/jesseduffield/lazygit/pull/3059)
- Re-apply filter when model changes by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3058](https://github.com/jesseduffield/lazygit/pull/3058)
- Use a PTY when calling external diff command by
[@&#8203;AFutureD](https://github.com/AFutureD) in
[https://github.com/jesseduffield/lazygit/pull/3120](https://github.com/jesseduffield/lazygit/pull/3120)
- Re-enable 'Unset upstream' option when upstream branch is missing by
[@&#8203;mark2185](https://github.com/mark2185) in
[https://github.com/jesseduffield/lazygit/pull/3086](https://github.com/jesseduffield/lazygit/pull/3086)
- Fall back to WithWaitingStatus if item is not visible by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3083](https://github.com/jesseduffield/lazygit/pull/3083)
- Fix checking out a tag when there is a branch with the same name by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3179](https://github.com/jesseduffield/lazygit/pull/3179)
- Fix preserving the commit message when description contains blank
lines by [@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3170](https://github.com/jesseduffield/lazygit/pull/3170)
- Allow multiple fetch commands (or fetch and pull) to run concurrently
by [@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3202](https://github.com/jesseduffield/lazygit/pull/3202)
- Support insteadOf URL rewriting when opening URLs in browser by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3177](https://github.com/jesseduffield/lazygit/pull/3177)
- Fix keybindings for characters involving AltGr on Windows by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3194](https://github.com/jesseduffield/lazygit/pull/3194)
- Do not include keybindings from another view in keybindings menu by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3220](https://github.com/jesseduffield/lazygit/pull/3220)
- Fix crash with short branch names by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3219](https://github.com/jesseduffield/lazygit/pull/3219)
- Keep same branch selected when fetching a branch while sorted by date
by [@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3186](https://github.com/jesseduffield/lazygit/pull/3186)
- Use git rev-parse to obtain repository and worktree paths by
[@&#8203;jwhitley](https://github.com/jwhitley) in
[https://github.com/jesseduffield/lazygit/pull/3183](https://github.com/jesseduffield/lazygit/pull/3183)
- Pass absolute file paths to all editor commands by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3255](https://github.com/jesseduffield/lazygit/pull/3255)
- Disallow cherry-picking merge commits by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3316](https://github.com/jesseduffield/lazygit/pull/3316)
- Fix two problems related to update-ref rebase todo items by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3290](https://github.com/jesseduffield/lazygit/pull/3290)
- Fix order of custom commands history by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3286](https://github.com/jesseduffield/lazygit/pull/3286)
- Fix some problems with patches if `git diff` was customized with
config (e.g. `external` or `noprefix`). by
[@&#8203;mricherzhagen](https://github.com/mricherzhagen) in
[https://github.com/jesseduffield/lazygit/pull/3222](https://github.com/jesseduffield/lazygit/pull/3222)
- Use $XDG_STATE_HOME for state.yml by
[@&#8203;horriblename](https://github.com/horriblename) in
[https://github.com/jesseduffield/lazygit/pull/2936](https://github.com/jesseduffield/lazygit/pull/2936)
- Fix display of Chinese characters on Windows by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3352](https://github.com/jesseduffield/lazygit/pull/3352)
- Allow more than one argument in git.merging.args config by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3336](https://github.com/jesseduffield/lazygit/pull/3336)
- Don't strike out reserved keys in menus by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3365](https://github.com/jesseduffield/lazygit/pull/3365)
- Don't ask to force-push if the remote rejected updates by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3387](https://github.com/jesseduffield/lazygit/pull/3387)
- Fix container detection by
[@&#8203;aritmos](https://github.com/aritmos) in
[https://github.com/jesseduffield/lazygit/pull/3412](https://github.com/jesseduffield/lazygit/pull/3412)

##### Maintenance ⚙️

- Add Click() to GuiDriver by
[@&#8203;simonwhitaker](https://github.com/simonwhitaker) in
[https://github.com/jesseduffield/lazygit/pull/2898](https://github.com/jesseduffield/lazygit/pull/2898)
- Add Makefile by [@&#8203;kyu08](https://github.com/kyu08) in
[https://github.com/jesseduffield/lazygit/pull/2937](https://github.com/jesseduffield/lazygit/pull/2937)
- fix GitHub Actions warnings by
[@&#8203;kyu08](https://github.com/kyu08) in
[https://github.com/jesseduffield/lazygit/pull/2950](https://github.com/jesseduffield/lazygit/pull/2950)
- Add instruction in PR template to start PRs with an imperative by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/2967](https://github.com/jesseduffield/lazygit/pull/2967)
- Don't show toasts when running integration tests by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/2975](https://github.com/jesseduffield/lazygit/pull/2975)
- Various debugging improvements by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3000](https://github.com/jesseduffield/lazygit/pull/3000)
- Rename `test/results` to `test/_results` by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3012](https://github.com/jesseduffield/lazygit/pull/3012)
- Support passing -race flag to integration tests by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3019](https://github.com/jesseduffield/lazygit/pull/3019)
- Improve debugging of integration tests by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3029](https://github.com/jesseduffield/lazygit/pull/3029)
- Use go:generate for cheatsheet by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3035](https://github.com/jesseduffield/lazygit/pull/3035)
- Change Makefile to build non-optimized by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3028](https://github.com/jesseduffield/lazygit/pull/3028)
- Update PR template to use go generate command by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3041](https://github.com/jesseduffield/lazygit/pull/3041)
- Band-aid fix for submodule/reset.go test failure by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3047](https://github.com/jesseduffield/lazygit/pull/3047)
- Remove redundant `len` check by
[@&#8203;Juneezee](https://github.com/Juneezee) in
[https://github.com/jesseduffield/lazygit/pull/3051](https://github.com/jesseduffield/lazygit/pull/3051)
- Add disabled compat for user config
([#&#8203;2833](https://github.com/jesseduffield/lazygit/issues/2833))
by [@&#8203;karimkhaleel](https://github.com/karimkhaleel) in
[https://github.com/jesseduffield/lazygit/pull/3060](https://github.com/jesseduffield/lazygit/pull/3060)
- Fix go.mod file by
[@&#8203;stefanhaller](https://github.com/stefanhaller) in
[https://github.com/jesseduffield/lazygit/pull/3118](https://github.com/jesseduffield/lazygit/pull/3118)
- Capture test code coverage stats by
[@&#8203;jesseduffield](https://github.com/jesseduffield) in
[https://github.com/jesseduffield/lazygit/pull/3135](https://github.com/jesseduffield/lazygit/pull/3135)
- fixed typo in test description by
[@&#8203;schuebel](https://github.com/schuebel) in
[https://github.com/jesseduffield/lazygit/pull/3101](https://github.com/jesseduffield/lazygit/pull/3101)
-   Update cheatsheets by [@&#8203;stefanhaller](https:

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "after 4pm on thursday" in timezone
America/Los_Angeles, Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get
[config help](https://github.com/renovatebot/renovate/discussions) if
that's undesired.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/scottames/dots).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4yNjEuMCIsInVwZGF0ZWRJblZlciI6IjM3LjI2OS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: scottames-github-bot[bot] <162828115+scottames-github-bot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants