fish path and add treesitter

This commit is contained in:
Barak Michener 2022-02-07 12:14:24 -08:00
parent e8626f8108
commit d10da3b71a
3 changed files with 60 additions and 1 deletions

View file

@ -1,4 +1,4 @@
set PATH ~/bin ~/.go/bin ~/.cargo/bin /bin /sbin /usr/local/bin /usr/local/sbin /usr/bin /usr/sbin ~/.cabal/bin /usr/lib/go/bin ~/.gem/ruby/1.9.1/bin $PATH
set PATH ~/bin ~/.local/bin ~/.go/bin ~/.cargo/bin /bin /sbin /usr/local/bin /usr/local/sbin /usr/bin /usr/sbin ~/.cabal/bin /usr/lib/go/bin ~/.gem/ruby/1.9.1/bin $PATH
set fish_greeting ""
set EDITOR vi

View file

@ -256,6 +256,60 @@ local dropdown = require'telescope.themes'.get_dropdown({
--winblend = 10
})
--
-- Treesitter
--
require'nvim-treesitter.configs'.setup {
-- One of "all", "maintained" (parsers with maintainers), or a list of languages
ensure_installed = {
"c",
"rust",
"python",
"go",
"javascript",
"typescript",
"markdown",
"fish",
"css",
"json",
"lua",
"make",
"svelte",
"vim",
"yaml",
},
-- Install languages synchronously (only applied to `ensure_installed`)
sync_install = false,
-- List of parsers to ignore installing
-- ignore_install = { "javascript" },
highlight = {
-- `false` will disable the whole extension
enable = true,
-- list of language that will be disabled
disable = { "c", "rust" },
-- 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).
-- Using this option may slow down your editor, and you may see some duplicate highlights.
-- Instead of true it can also be a list of languages
additional_vim_regex_highlighting = false,
},
indent = {
enable = true
},
}
--
-- Helper functions for my own grepping commands.
--
live_grep_repo = function(conf)
--local opt = dropdown
local opt = {
@ -275,6 +329,9 @@ git_grep_word = function(conf)
end
---
--- My own "where" clause generator for Rust
---
function string.insert(str1, str2, pos)
return str1:sub(1,pos)..str2..str1:sub(pos+1)
end

2
.vimrc
View file

@ -223,6 +223,8 @@ Plug 'folke/trouble.nvim'
Plug 'Shougo/defx.nvim', { 'do': ':UpdateRemotePlugins' }
Plug 'kristijanhusak/defx-icons'
Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
"Plug 'ggandor/lightspeed.nvim'
Plug 'justinmk/vim-sneak'