For *.rs.erb, set eruby_subtype to "rust"
This commit is contained in:
parent
5723c9d3c2
commit
99a9603b87
@ -102,3 +102,14 @@ vim.api.nvim_create_autocmd({ "FocusGained", "BufEnter" }, {
|
|||||||
})
|
})
|
||||||
|
|
||||||
vim.filetype.add({filename = {["Rsconscript"] = "ruby"}})
|
vim.filetype.add({filename = {["Rsconscript"] = "ruby"}})
|
||||||
|
|
||||||
|
-- Treat *.rs.erb files as eruby with an embedded Rust subtype
|
||||||
|
vim.filetype.add({
|
||||||
|
pattern = {
|
||||||
|
[".*%.rs%.erb"] = function(_, bufnr)
|
||||||
|
return "eruby", function()
|
||||||
|
vim.b[bufnr].eruby_subtype = "rust"
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user