neogit icon indicating copy to clipboard operation
neogit copied to clipboard

Buffer not updating after discard in Neogit

Open reybits opened this issue 9 months ago • 0 comments

Description

When a buffer with unsaved changes is discarded from Neogit, its contents do not update after closing the Neogit window. The changes are discarded, but the buffer still displays the old content until manually reloaded.

Is this an issue with my Neogit configuration, or could I have misconfigured something in my Neovim setup?

Thanks!

Neovim version

NVIM v0.10.4 Build type: Release LuaJIT 2.1.1736781742

Operating system and version

macOS 15.3.2

Steps to reproduce

  1. Edit a file and make some changes.
  2. Open Neogit.
  3. Discard changes in that file using (x).
  4. Close Neogit.

Expected behavior

The buffer content should update to match the file’s state in Git after discarding the changes.

Actual behavior

The buffer content still shows the changes that were discarded using the discard command.

Minimal config

Nothing unusual, default Neogit config.

reybits avatar Mar 16 '25 17:03 reybits