Skip to content

Commit

Permalink
fix(slash_cmd): include buffer number
Browse files Browse the repository at this point in the history
  • Loading branch information
olimorris committed Sep 19, 2024
1 parent 881dd06 commit 9ef7840
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion lua/codecompanion/helpers/slash_commands/buffer.lua
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,15 @@ local function output(SlashCommand, selected)
end

local Chat = SlashCommand.Chat
Chat:append_to_buf({ content = "[!" .. CONSTANTS.NAME .. ": `" .. selected[CONSTANTS.DISPLAY] .. "`]\n" })
Chat:append_to_buf({
content = "[!"
.. CONSTANTS.NAME
.. ": `"
.. selected[CONSTANTS.DISPLAY]
.. "` / Buf No.: "
.. selected.bufnr
.. "]\n",
})
Chat:append_to_buf({ content = content })
Chat:fold_code()
end
Expand Down

0 comments on commit 9ef7840

Please sign in to comment.