add selected command to cmd-history (#383)

This commit is contained in:
Senghan Bright
2021-01-04 07:09:55 +01:00
committed by GitHub
parent 4691863f43
commit 6a403ddf98

View File

@@ -180,7 +180,7 @@ actions.set_command_line = function(prompt_bufnr)
local entry = actions.get_selected_entry(prompt_bufnr) local entry = actions.get_selected_entry(prompt_bufnr)
actions.close(prompt_bufnr) actions.close(prompt_bufnr)
vim.fn.histadd("cmd", entry.value)
vim.cmd(entry.value) vim.cmd(entry.value)
end end