[vim] Detect Hugo HTML templates when there's a layouts component in the path
This commit is contained in:
parent
a0baeac863
commit
7eed873e02
1 changed files with 7 additions and 0 deletions
7
config/nvim/ftdetect/gohtmltmpl.lua
Normal file
7
config/nvim/ftdetect/gohtmltmpl.lua
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
-- Eryn Wells <eryn@erynwells.me>
|
||||||
|
|
||||||
|
-- Detect layout templates in Hugo projects
|
||||||
|
vim.api.nvim_create_autocmd({"BufRead", "BufNewFile"}, {
|
||||||
|
pattern = {"*/layouts/*.html"},
|
||||||
|
command = "setfiletype gohtmltmpl"
|
||||||
|
})
|
Loading…
Add table
Add a link
Reference in a new issue