mirror of
https://github.com/hexedtech/codemp-nvim.git
synced 2024-11-22 07:24:52 +01:00
fix: set ft after detecting
This commit is contained in:
parent
f2121df6dc
commit
661985c62b
1 changed files with 2 additions and 1 deletions
|
@ -90,7 +90,8 @@ local function attach(name, buffer, content, nowait)
|
|||
controller:callback(function (_controller) async:send() end)
|
||||
vim.defer_fn(function() async:send() end, 500) -- force a try_recv after 500ms
|
||||
|
||||
vim.filetype.match({ buf = buffer })
|
||||
local filetype = vim.filetype.match({ buf = buffer })
|
||||
vim.api.nvim_set_option_value("filetype", filetype, { buf = buffer })
|
||||
print(" ++ attached to buffer " .. name)
|
||||
return controller
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue