1007 do not wipe modified buffers when hijack unnamed buffer when opening (#1009)
This commit is contained in:
committed by
GitHub
parent
589e39d642
commit
a1937ca079
@@ -129,6 +129,7 @@ function M.open(cwd)
|
||||
local bufnr = api.nvim_get_current_buf()
|
||||
if M.hijack_unnamed_buffer_when_opening
|
||||
and api.nvim_buf_get_name(bufnr) == ""
|
||||
and not api.nvim_buf_get_option(bufnr, "modified")
|
||||
and api.nvim_buf_get_option(bufnr, "ft") == "" then
|
||||
view.open_in_current_win()
|
||||
renderer.draw()
|
||||
|
||||
Reference in New Issue
Block a user