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

"Local branches" when working with git trees #3561

Open
scallaway opened this issue May 15, 2024 · 0 comments
Open

"Local branches" when working with git trees #3561

scallaway opened this issue May 15, 2024 · 0 comments

Comments

@scallaway
Copy link
Contributor

Discussion was the best label to put this under, but it's more a question for my understanding.

I've started using Worktrees as I finally have a decent use-case for them, but the one thing I'm noticing is that Lazygit seems to report all the branches that are on remote as "Local branches", even if they don't have any upstream associated with them.

In my case, this results in some 700 branches being listed in the "local branches", where I try and keep that as clean as possible (removing local branches that have been deleted on remote).

Is this purely because I cloned the repository with --bare? Or is it due to the interaction with worktrees. I didn't want to clone regularly and then work with worktrees as the additional folders it creates (for each worktree) would confuse things.

I've also tried running a git remote prune origin now that I've added an upstream, but that doesn't seem to sort things either.

Just some clarification on how this works would be great! (And anyway to clear out those excess branches)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant