aboutsummaryrefslogtreecommitdiff
path: root/nvim
diff options
context:
space:
mode:
authorThomas Schmucker <ts@its1.de>2023-04-02 21:02:01 +0200
committerThomas Schmucker <ts@its1.de>2023-04-02 21:02:01 +0200
commit2d3d838cd3147ec3412e5b01051b5d5cf891ed88 (patch)
treeddb5d5c43f7e9fb37822f11f23244c1371eb20e6 /nvim
parentb7b34ea4744205815abba828ec6ec1a82cefdcf1 (diff)
downloaddotfiles-2d3d838cd3147ec3412e5b01051b5d5cf891ed88.tar.gz
dotfiles-2d3d838cd3147ec3412e5b01051b5d5cf891ed88.tar.bz2
dotfiles-2d3d838cd3147ec3412e5b01051b5d5cf891ed88.zip
Konfiguration für Treesitter
Diffstat (limited to 'nvim')
-rw-r--r--nvim/ftplugin/c.vim3
-rw-r--r--nvim/ftplugin/html.vim3
-rw-r--r--nvim/plugins.vim17
3 files changed, 21 insertions, 2 deletions
diff --git a/nvim/ftplugin/c.vim b/nvim/ftplugin/c.vim
index e0c347d..fd45dbd 100644
--- a/nvim/ftplugin/c.vim
+++ b/nvim/ftplugin/c.vim
@@ -4,4 +4,5 @@ setlocal formatoptions=tcqr
4setlocal cindent 4setlocal cindent
5 5
6setlocal foldenable 6setlocal foldenable
7setlocal foldmethod=syntax 7setlocal foldmethod=expr
8setlocal foldexpr=nvim_treesitter#foldexpr()
diff --git a/nvim/ftplugin/html.vim b/nvim/ftplugin/html.vim
index fced505..fe513b6 100644
--- a/nvim/ftplugin/html.vim
+++ b/nvim/ftplugin/html.vim
@@ -6,7 +6,8 @@ setlocal expandtab
6setlocal autoindent 6setlocal autoindent
7 7
8setlocal foldenable 8setlocal foldenable
9setlocal foldmethod=indent 9setlocal foldmethod=expr
10setlocal foldexpr=nvim_treesitter#foldexpr()
10 11
11let g:html_indent_script1='inc' 12let g:html_indent_script1='inc'
12let g:html_indent_style1='inc' 13let g:html_indent_style1='inc'
diff --git a/nvim/plugins.vim b/nvim/plugins.vim
index 4c0d9a0..1386eca 100644
--- a/nvim/plugins.vim
+++ b/nvim/plugins.vim
@@ -16,6 +16,7 @@ call plug#begin()
16 Plug 'simnalamburt/vim-mundo' 16 Plug 'simnalamburt/vim-mundo'
17 Plug 'tpope/vim-repeat' 17 Plug 'tpope/vim-repeat'
18 Plug 'tpope/vim-surround' 18 Plug 'tpope/vim-surround'
19 Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
19call plug#end() 20call plug#end()
20 21
21" EMMET 22" EMMET
@@ -48,3 +49,19 @@ let g:mundo_preview_height=30
48" Autopairs 49" Autopairs
49let b:autopairs_enabled=1 50let b:autopairs_enabled=1
50 51
52" Treesitter
53lua << EOF
54require'nvim-treesitter.configs'.setup {
55 ensure_installed = { "c", "lua", "vim", "vimdoc", "typescript" },
56 sync_install = false,
57 auto_install = false,
58 highlight = {
59 enable = true,
60 disable = { "html" },
61 additional_vim_regex_highlighting = true,
62 },
63 indent = {
64 enable = false,
65 },
66}
67EOF