From 243d5422918d68431f074dc6da24d71dab20a475 Mon Sep 17 00:00:00 2001 From: "flyingscorpio@clevo" Date: Mon, 23 Jan 2023 10:21:53 +0100 Subject: [PATCH] Ignore html for treesitter, add html to jinja2 ft detection --- roles/neovim/files/after/plugin/ansible.lua | 6 ++++++ roles/neovim/files/after/plugin/treesitter.lua | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 roles/neovim/files/after/plugin/ansible.lua diff --git a/roles/neovim/files/after/plugin/ansible.lua b/roles/neovim/files/after/plugin/ansible.lua new file mode 100644 index 0000000..51e389d --- /dev/null +++ b/roles/neovim/files/after/plugin/ansible.lua @@ -0,0 +1,6 @@ +-- ansible-vim + +vim.g.ansible_template_syntaxes = { + ['*.html.j2'] = 'html', + ['*.sh.j2'] = 'sh', +} diff --git a/roles/neovim/files/after/plugin/treesitter.lua b/roles/neovim/files/after/plugin/treesitter.lua index e0cbbc2..97a7966 100644 --- a/roles/neovim/files/after/plugin/treesitter.lua +++ b/roles/neovim/files/after/plugin/treesitter.lua @@ -18,7 +18,7 @@ require'nvim-treesitter.configs'.setup { -- disable highlighting for the `tex` filetype, you need to include `latex` in this list as this is -- the name of the parser) -- list of language that will be disabled - disable = { "diff", "gitcommit", "latex", "make", "yaml" }, + disable = { "diff", "gitcommit", "html", "latex", "make", "yaml" }, -- Setting this to true will run `:h syntax` and tree-sitter at the same time. -- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).