hrsh7th / nvim-cmp

A completion plugin for neovim coded in Lua.
MIT License
8.01k stars 398 forks source link

Unsaved buffer error with vim-startify session #296

Closed ranebrown closed 3 years ago

ranebrown commented 3 years ago

When using a vim-startify session the completion popup seems to stick around as an unsaved buffer.

  1. Download minimal_init.txt

  2. Rename to minimal_init.lua

  3. nvim -u minimal_init.lua test.txt

  4. Add text to buffer and save.

  5. Save a session using SSave mysession

  6. :quit

  7. nvim -u minimal_init.lua

  8. :SLoad mysession

  9. Type some text that causes completion menu to appear and try to save and quit :wq.

  10. This will result in an error message:

    E37: No write since last change
    E162: No write since last change for buffer "[No Name]"
    Press ENTER or type command to continue
  11. Pressing enter will drop into a buffer with the text from the completion popup window.

ranebrown commented 3 years ago

Could be related to #291

ranebrown commented 3 years ago

@hrsh7th Thanks for looking into this. This change you pushed doesn't seem to fix the issue though.

ranebrown commented 3 years ago

That fixes it! Thanks!