zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
50.93k stars 3.15k forks source link

Files don't reload new content from disk #18534

Open thomaseizinger opened 2 months ago

thomaseizinger commented 2 months ago

Check for existing issues

Describe the bug / provide steps to reproduce it

I have a test that produces output files which are Git-ignored. Re-running the test changes the files. Yet, if I have one of the files open in Zed, it will happily show me the previous, essentially stale output.

This has tripped me up a few times now where I didn't realise that I am looking at stale logs.

Environment

Zed: v0.155.0 (Zed Dev) OS: Linux Wayland nixos 24.05 Memory: 60.6 GiB Architecture: x86_64 GPU: AMD Radeon Graphics (RADV GFX1103_R1) || radv || Mesa 24.0.7

If applicable, add mockups / screenshots to help explain present your vision of the feature

Zed should check if the file has changed on disk when a tab gets focused.

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

Zed.log


medz commented 2 months ago

This is a very old bug that has existed since zed was released.

In some special cases, when you need to modify files with other tools, zed will have such an error.

Hope it can be fixed as soon as possible

thomaseizinger commented 2 months ago

I now realise that it does somehow check because it displays a small dot next to it. I need to proactively close the tab and reopen it which is kind of annoying. It would be nice if Zed promoted me on focus whether I want to reload the file.

alexgodin commented 1 month ago

I’m voting for a better UI here please. This small dot is hard for me to notice as well (and then hard to reload the file when I do notice).