-
Notifications
You must be signed in to change notification settings - Fork 72
Description
Not necessarily a bug, so using a blank issue.
When using vim-suda's g:suda_smart_edit = 1 config to automatically open sudo-requiring files in a suda:// buffer, markview can have a race interaction and will inconsistently error out at:
plugin/markview.lua:323
local bt, ft = vim.bo[buffer].buftype, vim.bo[buffer].filetype;with error Invalid buffer id: 1, as vim-suda wipes the originally invoked non-readable buffer and replaces it with a new buffer with a different id. I'm also assuming that in the case that it does not error out in the same scenario, markview executes code twice.
I don't think there is a good alternative for vim-suda at the moment, and neovim still doesn't have a convenient builtin solution, so I'm not considering removing it for now.
Is there a workaround I can use within markview? Maybe a delay of sorts. Otherwise, if this is an issue I should raise with vim-suda's maintainer instead, please feel free to let me know.