Adds treesitter and biscuit plugins + tweak to sudo write
The two plugins were added along with relevant configuration for each If in neovim and sudo_askpass isn't set, vim will display a warning if WW is typed in command mode
This commit is contained in:
parent
7cb88eb204
commit
8ea14abe9e
8 changed files with 36 additions and 0 deletions
6
.gitmodules
vendored
6
.gitmodules
vendored
|
@ -73,3 +73,9 @@
|
|||
[submodule "nvim/.config/nvim/pack/bundle/opt/lexima.vim"]
|
||||
path = nvim/.config/nvim/pack/bundle/opt/lexima.vim
|
||||
url = https://github.com/cohama/lexima.vim
|
||||
[submodule "nvim/.config/nvim/pack/bundle/nvim-biscuits"]
|
||||
path = nvim/.config/nvim/pack/bundle/opt/nvim-biscuits
|
||||
url = https://github.com/code-biscuits/nvim-biscuits
|
||||
[submodule "nvim/.config/nvim/pack/bundle/opt/nvim-treesitter"]
|
||||
path = nvim/.config/nvim/pack/bundle/opt/nvim-treesitter
|
||||
url = https://github.com/nvim-treesitter/nvim-treesitter
|
||||
|
|
1
nvim/.config/nvim/after/plugin/biscuit.vim
Normal file
1
nvim/.config/nvim/after/plugin/biscuit.vim
Normal file
|
@ -0,0 +1 @@
|
|||
highlight BiscuitColor gui=italic
|
|
@ -22,6 +22,8 @@ if has('packages')
|
|||
packadd! deoplete-lsp
|
||||
packadd! deoplete-notmuch
|
||||
packadd! firenvim
|
||||
packadd! nvim-treesitter
|
||||
packadd! nvim-biscuits
|
||||
lua <<EOF
|
||||
if ( vim.lsp ~= nil ) then
|
||||
vim.cmd "packadd! nvim-lspconfig"
|
||||
|
|
1
nvim/.config/nvim/pack/bundle/opt/nvim-biscuits
Submodule
1
nvim/.config/nvim/pack/bundle/opt/nvim-biscuits
Submodule
|
@ -0,0 +1 @@
|
|||
Subproject commit 15a0cb1273bd36d5a734210cdc3406fb4bcfb733
|
|
@ -0,0 +1 @@
|
|||
Subproject commit a47df48e7d4232fd771f2537a4fb43f582c026c9
|
12
nvim/.config/nvim/plugin/biscuits.vim
Normal file
12
nvim/.config/nvim/plugin/biscuits.vim
Normal file
|
@ -0,0 +1,12 @@
|
|||
lua <<EOF
|
||||
require('nvim-biscuits').setup({
|
||||
default_config = {
|
||||
min_distance = 3,
|
||||
prefix_string = " "
|
||||
},
|
||||
show_on_start = true,
|
||||
toggle_keybind = "<leader>cb"
|
||||
})
|
||||
|
||||
EOF
|
||||
|
|
@ -85,6 +85,8 @@ nnoremap <leader>p :call mine#functions#proselint()<CR>
|
|||
if has('nvim')
|
||||
if !empty($SUDO_ASKPASS)
|
||||
cnoremap WW w !sudo -A tee % > /dev/null
|
||||
else
|
||||
cnoremap WW echo "SUDO_ASKPASS variable needs to be set"<cr>
|
||||
endif
|
||||
else
|
||||
cnoremap WW w !sudo tee % > /dev/null
|
||||
|
|
11
nvim/.config/nvim/plugin/treesitter.vim
Normal file
11
nvim/.config/nvim/plugin/treesitter.vim
Normal file
|
@ -0,0 +1,11 @@
|
|||
lua <<EOF
|
||||
require'nvim-treesitter.configs'.setup {
|
||||
ensure_installed = "all",
|
||||
highlight = {
|
||||
enable = true
|
||||
},
|
||||
indent = {
|
||||
enable = true
|
||||
}
|
||||
}
|
||||
EOF
|
Loading…
Add table
Add a link
Reference in a new issue