diff options
| author | Ramon Asuncion <asuncionbatista@gmail.com> | 2026-01-14 14:26:43 -0500 |
|---|---|---|
| committer | Ramon Asuncion <asuncionbatista@gmail.com> | 2026-01-14 14:26:43 -0500 |
| commit | 63c0cd6ee9bf52d1d032d06f6b70486ed0e26c07 (patch) | |
| tree | 071d7ac9891c0bd605c8a74e1f9adb376abf92c0 /scripts | |
| parent | c628dda5b675c8724ea641bfc0dd1f6e4b01483f (diff) | |
| parent | 91ea4cfd4a46d756152e9470abe495f4b178e818 (diff) | |
| download | a4-63c0cd6ee9bf52d1d032d06f6b70486ed0e26c07.tar.xz a4-63c0cd6ee9bf52d1d032d06f6b70486ed0e26c07.zip | |
Merge remote-tracking branch 'origin/master' into add-elixir-support
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/tests/minimal.vim | 48 |
1 files changed, 33 insertions, 15 deletions
diff --git a/scripts/tests/minimal.vim b/scripts/tests/minimal.vim index a7e1e36..a8d3d7d 100644 --- a/scripts/tests/minimal.vim +++ b/scripts/tests/minimal.vim @@ -1,20 +1,38 @@ -set noswapfile +" covers all package managers i am willing to cover set rtp+=. +set rtp+=../plenary.nvim +set rtp+=../nvim-treesitter +set rtp+=~/.vim/plugged/plenary.nvim +set rtp+=~/.vim/plugged/nvim-treesitter +set rtp+=~/.local/share/nvim/site/pack/packer/start/plenary.nvim +set rtp+=~/.local/share/nvim/site/pack/packer/start/nvim-treesitter +set rtp+=~/.local/share/lunarvim/site/pack/packer/start/plenary.nvim +set rtp+=~/.local/share/lunarvim/site/pack/packer/start/nvim-treesitter +set rtp+=~/.local/share/nvim/lazy/plenary.nvim +set rtp+=~/.local/share/nvim/lazy/nvim-treesitter -let s:paths = [ - \ "../plenary.nvim", - \ expand("~/.local/share/nvim/lazy/plenary.nvim"), - \ expand("~/.local/share/nvim/site/pack/*/start/plenary.nvim"), - \ expand("~/.config/nvim/pack/*/start/plenary.nvim"), - \ expand("~/.config/nvim/plugged/plenary.nvim"), - \ ] - -for s:path in s:paths - if isdirectory(s:path) - execute "set rtp+=" . s:path - break - endif -endfor +set autoindent +set tabstop=4 +set expandtab +set shiftwidth=4 +set noswapfile runtime! plugin/plenary.vim +runtime! plugin/nvim-treesitter.lua +lua <<EOF +local required_parsers = { + 'c', 'cpp', 'go', 'lua', 'php', 'python', 'typescript', 'javascript', 'java', 'ruby', 'tsx', 'c_sharp', 'vue' +} +local installed_parsers = require'nvim-treesitter.info'.installed_parsers() +local to_install = vim.tbl_filter(function(parser) + return not vim.tbl_contains(installed_parsers, parser) +end, required_parsers) +if #to_install > 0 then + -- fixes 'pos_delta >= 0' error - https://github.com/nvim-lua/plenary.nvim/issues/52 + vim.cmd('set display=lastline') + -- make "TSInstall*" available + vim.cmd 'runtime! plugin/nvim-treesitter.vim' + vim.cmd('TSInstallSync ' .. table.concat(to_install, ' ')) +end +EOF |
