replace some plugins for nvim
This commit is contained in:
+28
-6
@@ -55,11 +55,6 @@
|
||||
Plug 'jiangmiao/auto-pairs'
|
||||
Plug 'mg979/vim-visual-multi'
|
||||
|
||||
Plug 'vim-airline/vim-airline'
|
||||
Plug 'vim-airline/vim-airline-themes'
|
||||
|
||||
" The bottom buffer display
|
||||
Plug 'bling/vim-bufferline'
|
||||
Plug 'easymotion/vim-easymotion'
|
||||
Plug 'vim-scripts/restore_view.vim'
|
||||
|
||||
@@ -77,10 +72,19 @@
|
||||
|
||||
" put text in neibouring tmux pane into auto complete
|
||||
Plug 'wellle/tmux-complete.vim'
|
||||
Plug 'NoahTheDuke/vim-just'
|
||||
|
||||
Plug 'ludovicchabant/vim-gutentags', { 'for': ['c', 'cpp'] }
|
||||
Plug 'lambdalisue/readablefold.vim'
|
||||
|
||||
" only work with vim
|
||||
if g:vim_type == 'vim'
|
||||
Plug 'vim-airline/vim-airline'
|
||||
Plug 'vim-airline/vim-airline-themes'
|
||||
endif
|
||||
|
||||
" The bottom buffer display
|
||||
Plug 'bling/vim-bufferline'
|
||||
" only work with nvim > 0.5
|
||||
" For other versions, just loading the plugin may
|
||||
" cause error
|
||||
@@ -92,12 +96,19 @@
|
||||
Plug 'EdenEast/nightfox.nvim'
|
||||
Plug 'projekt0n/github-nvim-theme'
|
||||
|
||||
Plug 'nvim-lualine/lualine.nvim'
|
||||
" If you want to have icons in your statusline choose one of these
|
||||
Plug 'kyazdani42/nvim-web-devicons'
|
||||
|
||||
" partial code execution
|
||||
" Plug 'michaelb/sniprun', {'do': 'bash install.sh'}
|
||||
endif
|
||||
if g:vim_version >= 0.7
|
||||
Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
|
||||
endif
|
||||
if g:vim_version >= 0.8
|
||||
Plug 'nvim-tree/nvim-tree.lua'
|
||||
endif
|
||||
endif
|
||||
|
||||
call plug#end()
|
||||
@@ -192,7 +203,7 @@ endif
|
||||
" }
|
||||
|
||||
" NerdTree {
|
||||
if isdirectory(expand(plugin_dir . "/nerdtree"))
|
||||
if g:vim_type == 'vim' && isdirectory(expand(plugin_dir . "/nerdtree"))
|
||||
let g:NERDShutUp=1
|
||||
|
||||
" work around for nerdtree bug: https://github.com/preservim/nerdtree/issues/1321
|
||||
@@ -211,6 +222,17 @@ endif
|
||||
let NERDTreeKeepTreeInNewTab = 1
|
||||
endif
|
||||
" }
|
||||
|
||||
" nvim-tree.lua {
|
||||
if g:vim_type == 'nvim' && isdirectory(expand(plugin_dir . "/nvim-tree.lua"))
|
||||
|
||||
|
||||
nnoremap <leader>e :NvimTreeFindFileToggle<CR>
|
||||
nnoremap <leader>r :NvimTreeRefresh<CR>
|
||||
" nnoremap <leader>e :NvimTreeFindFile<CR>
|
||||
|
||||
endif
|
||||
" }
|
||||
|
||||
"if has('nvim') && str2float(g:nvim_version) >= 0.5 && isdirectory(expand(plugin_dir . "/lualine.nvim"))
|
||||
" nvim-lualine/lualine.nvim {
|
||||
|
||||
+73
-1
@@ -1,5 +1,5 @@
|
||||
|
||||
require'nvim-treesitter.configs'.setup {
|
||||
require('nvim-treesitter.configs').setup {
|
||||
-- ensure_installed = { "c", "bash", "lua" },
|
||||
sync_install = false,
|
||||
auto_install = true,
|
||||
@@ -9,3 +9,75 @@ require'nvim-treesitter.configs'.setup {
|
||||
additional_vim_regex_highlighting = false,
|
||||
},
|
||||
}
|
||||
|
||||
require('lualine').setup {
|
||||
sections = {
|
||||
lualine_a = {'mode'},
|
||||
lualine_b = {},
|
||||
lualine_c = {
|
||||
{
|
||||
'buffers',
|
||||
mode = 4,
|
||||
}
|
||||
},
|
||||
-- lualine_x = {'encoding', 'fileformat', 'filetype'},
|
||||
lualine_x = {'encoding'},
|
||||
lualine_y = {},
|
||||
lualine_z = {'location'}
|
||||
},
|
||||
-- tabline = {
|
||||
-- lualine_a = {
|
||||
-- {
|
||||
-- 'buffers',
|
||||
-- mode = 4,
|
||||
-- }
|
||||
-- },
|
||||
-- lualine_b = {},
|
||||
-- lualine_c = {},
|
||||
-- lualine_x = {},
|
||||
-- lualine_y = {},
|
||||
-- lualine_z = {'tabs'}
|
||||
-- },
|
||||
-- winbar = {
|
||||
-- lualine_a = {},
|
||||
-- lualine_b = {},
|
||||
-- lualine_c = {'filename'},
|
||||
-- lualine_x = {},
|
||||
-- lualine_y = {},
|
||||
-- lualine_z = {}
|
||||
-- },
|
||||
}
|
||||
|
||||
-- nvim-tree configuration
|
||||
--
|
||||
|
||||
-- disable netrw at the very start of your init.lua (strongly advised)
|
||||
vim.g.loaded_netrw = 1
|
||||
vim.g.loaded_netrwPlugin = 1
|
||||
|
||||
-- set termguicolors to enable highlight groups
|
||||
vim.opt.termguicolors = true
|
||||
|
||||
-- setup with some options
|
||||
require("nvim-tree").setup({
|
||||
sort_by = "case_sensitive",
|
||||
view = {
|
||||
width = 30,
|
||||
mappings = {
|
||||
list = {
|
||||
{ key = "C-[", action = "dir_up" },
|
||||
{ key = "C-]", action = "cd" },
|
||||
{ key = "<C-k>", action = "toggle_file_info" },
|
||||
},
|
||||
},
|
||||
},
|
||||
renderer = {
|
||||
group_empty = true,
|
||||
},
|
||||
filters = {
|
||||
dotfiles = false,
|
||||
},
|
||||
})
|
||||
|
||||
--
|
||||
-- nvim-tree configuration end
|
||||
|
||||
Reference in New Issue
Block a user