-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
I'm still unclear on how exactly this happened, but I had a repo with a local branch whose name was an empty string. Lazygit was unable to see any of my local branches or remotes on this repo.
Of note, Lazygit is still able to see the commit history on the current branch, even if it doesn't display the list of branches.
To Reproduce
Steps to reproduce the behavior:
- Clone or init any repo.
- Manually edit
.git/configto have a[branch ""]section indicating a branch with an empty name. You don't need to create anything in this section. - Run Lazygit and inspect the local branches and remotes section.
Expected behavior
The empty branch name should either be ignored, or else there should be an error somewhere that .git/config is invalid.
Screenshots
Version info:
commit=17d03ec8cb89d4c65fd129228164562a220abefb, build date=2025-12-06T13:01:50Z, build source=binaryRelease, version=0.57.0, os=linux, arch=amd64, git version=2.34.1
git version 2.34.1
Additional context
Add any other context about the problem here.
None.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working