Skip to content

Stale files when used as $GIT_EDITOR #61278

Description

@injust

Reproduction steps

  1. Configure Zed as your $GIT_EDITOR:
{ "terminal": { "env": { "GIT_EDITOR": "zed --wait" } } }
  1. Run the following in the integrated terminal:
touch foo
git add foo
git commit
  1. Type any non-empty commit message, then save and close the file to commit
  2. Run the following in the integrated terminal:
touch bar
git add bar
git commit

Current vs. Expected behavior

After the 2nd git commit, the COMMIT_EDITMSG file opens with the commit message from the 1st invocation. The file has changed on disk, but is not reflected in Zed.

Zed version and system specs

Zed: v1.11.3+stable.326.952d712dac48a4af2c54fb22c82d82a9d69b72d4 (Zed)
OS: macOS 15.7.7
Memory: 16 GiB
Architecture: x86_64

Metadata

Metadata

Assignees

No one assigned

    Labels

    community championIssues filed by our amazing community champions! 🫶state:needs triagetriage is not complete: no `area:*` label, or no `priority:*`/`frequency:*` for Bugs/Crashes

    Type

    Fields

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions