[nvim] Add filetypes settings
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
require("config.autocmds")
|
||||
require("config.options")
|
||||
require("config.filetypes")
|
||||
require("config.keymaps")
|
||||
require("config.options")
|
||||
|
||||
require("config.lazy")
|
||||
require("config.theme") -- ignored by git
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
vim.filetype.add({
|
||||
pattern = {
|
||||
[".*%.tmpl"] = function(path, _)
|
||||
local ext = path:match("%.(%w+)%.tmpl$")
|
||||
if ext then
|
||||
return ext
|
||||
end
|
||||
|
||||
return "template"
|
||||
end,
|
||||
},
|
||||
})
|
||||
@@ -1,32 +1,33 @@
|
||||
return {
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
lazy = false,
|
||||
build = ":TSUpdate",
|
||||
config = function()
|
||||
require("nvim-treesitter").install({
|
||||
"c",
|
||||
"caddy",
|
||||
"c_sharp",
|
||||
"css",
|
||||
"csv",
|
||||
"html",
|
||||
"javascript",
|
||||
"json",
|
||||
"nix",
|
||||
"sql",
|
||||
"typescript",
|
||||
"vimdoc",
|
||||
"zsh",
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||
branch = "main",
|
||||
init = function()
|
||||
vim.g.no_plugin_maps = true
|
||||
end,
|
||||
opts = {}
|
||||
}
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
lazy = false,
|
||||
build = ":TSUpdate",
|
||||
config = function()
|
||||
require("nvim-treesitter").install({
|
||||
"bash",
|
||||
"c",
|
||||
"caddy",
|
||||
"c_sharp",
|
||||
"css",
|
||||
"csv",
|
||||
"html",
|
||||
"javascript",
|
||||
"json",
|
||||
"nix",
|
||||
"sql",
|
||||
"typescript",
|
||||
"vimdoc",
|
||||
"zsh",
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||
branch = "main",
|
||||
init = function()
|
||||
vim.g.no_plugin_maps = true
|
||||
end,
|
||||
opts = {}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user