Skip to content

Commit

Permalink
fix: multi-line desc not captured properly
Browse files Browse the repository at this point in the history
  • Loading branch information
rockyzhang24 authored and ibhagwan committed Dec 26, 2024
1 parent 7307943 commit e724f50
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lua/fzf-lua/providers/nvim.lua
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,10 @@ M.commands = function(opts)
if cmd then builtin_commands[cmd] = desc end
cmd, desc = line:match("^|:(%S+)|%s*%S+%s*(.*%S)")
elseif cmd then -- found
if line:match("^%s%+%S") then desc = desc .. (line:match("^%s*(.*%S)") or "") end
if line:match("^%s+%S") then
local desc_continue = line:match("^%s*(.*%S)")
desc = desc .. (desc_continue and " " .. desc_continue or "")
end
if line:match("^%s*$") then break end
end
end
Expand Down

0 comments on commit e724f50

Please sign in to comment.