diff --git a/doc/command-t.txt b/doc/command-t.txt index cfe9a3b0..04408409 100644 --- a/doc/command-t.txt +++ b/doc/command-t.txt @@ -609,7 +609,8 @@ HISTORY *command-t-history* main (not yet released) ~ -- ... +- fix: teach buffer finder to see all buffers passed into Neovim as + command-line arguments (https://github.com/wincent/command-t/issues/418). 6.0.0-b.1 (16 December 2022) ~ diff --git a/lua/wincent/commandt/init.lua b/lua/wincent/commandt/init.lua index 59c23e92..20f8e15a 100644 --- a/lua/wincent/commandt/init.lua +++ b/lua/wincent/commandt/init.lua @@ -161,7 +161,7 @@ local default_options = { local handles = vim.api.nvim_list_bufs() local paths = {} for _, handle in ipairs(handles) do - if vim.api.nvim_buf_is_loaded(handle) then + if vim.api.nvim_buf_is_valid(handle) then local name = vim.api.nvim_buf_get_name(handle) if name ~= '' then local relative = vim.fn.fnamemodify(name, ':~:.')