mfussenegger / nvim-jdtls

Extensions for the built-in LSP support in Neovim for eclipse.jdt.ls
GNU General Public License v3.0
1.09k stars 62 forks source link

Rename java public class name, the class filename is not renamed at the same time. #281

Closed qianwch closed 2 years ago

qianwch commented 2 years ago

LSP client configuration

https://gist.github.com/qianweichun/6ef447bd06453870b377f7165495763e

Eclipse.jdt.ls version

1.13.0

Steps to Reproduce

  1. Open a Java Project
  2. Locate and open a Java public class.
  3. Rename the java class name with vim.lsp.buf.rename()

Expected Result

The public class name and filename renames at the same time.

Actual Result

The class name renamed without the filename renaming at the same time.

mfussenegger commented 2 years ago

I can't reproduce this. It works fine for me.

qianwch commented 2 years ago

It is proved that the problem is about the sample config :

    local config = {
        flags = {
          allow_incremental_sync = true,
        };
        capabilities = capabilities,
        on_attach = on_attach,
    }

After comment out apabilities = capabilities,, the problem disappears...