Skip to content

Commit 486a061

Browse files
XXiaoARobitx
authored andcommitted
fix: set the popup window to markdown filetype
1 parent 33a4d69 commit 486a061

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lua/gp/init.lua

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1573,6 +1573,8 @@ M.open_buf = function(file_name, target, kind, toggle)
15731573
-- read file into buffer and force write it
15741574
vim.api.nvim_command("silent 0read " .. file_name)
15751575
vim.api.nvim_command("silent file " .. file_name)
1576+
-- set the filetype to markdown
1577+
vim.api.nvim_buf_set_option(buf, "filetype", "markdown")
15761578
else
15771579
-- move cursor to the beginning of the file and scroll to the end
15781580
M._H.feedkeys("ggG", "xn")

0 commit comments

Comments
 (0)