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

Bug: git gutter status not update after git add, nested workdir's .git is soft link #21965

Open
1 task done
can2049 opened this issue Dec 13, 2024 · 0 comments
Open
1 task done
Labels
admin read Pending admin review bug [core label] triage Maintainer needs to classify the issue

Comments

@can2049
Copy link
Contributor

can2049 commented Dec 13, 2024

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

Hi, I just commited a code patch, to fix that zed cannot recognize a git repo when workdir's .git is a soft link. This is the Pull Request #21153

Then I found a new bug.
When i tried to open from a google repo managed mono-repo. Git gutter status works not well.

how to produce?

mkdir monorepo_demo
cd monorepo_demo
mkdir .repo

mkdir good_repo
cd good_repo
echo "hello" > good.txt
git init
git add .
git commit -m "init"

# goto monorepo root
cd ..
mkdir bad_repo
echo "hello" > bad.txt
git init
git add .
git commit -m "init"
mv .git ../.repo/bag_repo.git
ln -sf  ../.repo/bag_repo.git .git

cd ..
# open Zed from monorepo root dir now
zed .

Then I got a monorepo with this file structure:

.
├── bad_repo
│   ├── bad.txt
│   └── .git -> ../.repo/bad_repo.git
├── good_repo
│   ├── .git
│   └── good.txt
└── .repo
    └── bad_repo.git

This is the screen record.
You can see the screen record, when I run git add . in the bad_repo, the git gutter status bar should disappear, but actually not.

Environment

Zed: v0.167.0 (Zed Dev 5318f52)
OS: Linux X11 ubuntu 20.04
Memory: 62.7 GiB
Architecture: x86_64
GPU: NVIDIA GeForce RTX 3060 || NVIDIA || 550.127.05

If applicable, add screenshots or screencasts of the incorrect state / behavior

output

If applicable, attach your Zed.log file to this issue.

Zed.log

@can2049 can2049 added admin read Pending admin review bug [core label] triage Maintainer needs to classify the issue labels Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
admin read Pending admin review bug [core label] triage Maintainer needs to classify the issue
Projects
None yet
Development

No branches or pull requests

1 participant