120 lines
2.8 KiB
VimL
120 lines
2.8 KiB
VimL
set nocompatible
|
|
set showmatch
|
|
set ignorecase
|
|
set hlsearch
|
|
set tabstop=4
|
|
set softtabstop=4
|
|
set shiftwidth=4
|
|
set autoindent
|
|
set number
|
|
set wildmode=longest,list
|
|
set cc=80
|
|
syntax on
|
|
set mouse=a
|
|
set clipboard=unnamedplus
|
|
set ttyfast
|
|
|
|
set splitright
|
|
set splitbelow
|
|
|
|
call plug#begin("~/.vim/plugged")
|
|
" Plugin section
|
|
" Code Completion
|
|
" Plug 'neoclide/coc.nvim', {'branch': 'release'}
|
|
" Theme
|
|
Plug 'ghifarit53/tokyonight-vim'
|
|
" Snippets Engine
|
|
Plug 'honza/vim-snippets'
|
|
" Icons for nerdtree
|
|
" Plug 'ryanoasis/vim-devicons'
|
|
" Mass comment
|
|
Plug 'preservim/nerdcommenter'
|
|
" Nerd tree for file exploring
|
|
" Plug 'scrooloose/nerdtree'
|
|
" Telescope for... uh...
|
|
Plug 'nvim-telescope/telescope.nvim'
|
|
" Start splash screen
|
|
" Plug 'mhinz/vim-startify'
|
|
" i guess that colored icons need web devicons?
|
|
Plug 'kyazdani42/nvim-web-devicons'
|
|
" also bufferline makes better tabs
|
|
Plug 'akinsho/bufferline.nvim'
|
|
"new nerdtree
|
|
Plug 'kyazdani42/nvim-tree.lua'
|
|
call plug#end()
|
|
|
|
"color schemes
|
|
let g:tokyonight_style = 'night'
|
|
let g:tokyonight_enable_italic = 1
|
|
colorscheme tokyonight
|
|
if (has("termguicolors"))
|
|
set termguicolors
|
|
endif
|
|
syntax enable
|
|
|
|
|
|
" move split panes around
|
|
nnoremap <A-h> <C-W>H
|
|
nnoremap <A-j> <C-W>J
|
|
nnoremap <A-k> <C-W>K
|
|
nnoremap <A-l> <C-W>L
|
|
|
|
" move between panes
|
|
nnoremap <A-h> <C-w>h
|
|
nnoremap <A-j> <C-w>j
|
|
nnoremap <A-k> <C-w>k
|
|
nnoremap <A-l> <C-w>l
|
|
|
|
" open NERDtree
|
|
nnoremap <leader>n :NvimTreeFocus<CR>
|
|
nnoremap <C-n> :NvimTreeOpen<CR>
|
|
nnoremap <C-t> :NvimTreeToggle<CR>
|
|
nnoremap <C-f> :NvimTreeFind<CR>
|
|
|
|
|
|
autocmd VimEnter * NvimTreeOpen
|
|
"autocmd BufEnter * if tabpagenr('$') == 1 && winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() | quit | endif
|
|
|
|
lua << EOF
|
|
require("bufferline").setup{
|
|
options = {
|
|
offsets = { { filetype = "NvimTree", text = "", padding = 1 } },
|
|
}
|
|
}
|
|
require'nvim-tree'.setup{
|
|
open_on_setup = true;
|
|
auto_close = true;
|
|
diagnostics = { enable = false };
|
|
disable_netrw = true;
|
|
hijack_cursor = true;
|
|
}
|
|
EOF
|
|
|
|
"let g:nvim_tree_auto_open = 1
|
|
"let g:nvim_tree_auto_close = 0
|
|
"let g:nvim_tree_auto_ignore_ft = ['startify', 'dashboard']
|
|
"let g:nvim_tree_quit_on_open = 0
|
|
"let g:nvim_tree_follow_update_path = 1
|
|
"let g:nvim_tree_indent_markers = 1
|
|
"let g:nvim_tree_hide_dotfiles = 0
|
|
"let g:nvim_tree_git_hl = "1
|
|
"let g:nvim_tree_highlight_opened_files = 1
|
|
"let g:nvim_tree_root_folder_modifier = ':~'
|
|
"let g:nvim_tree_tab_open = 1
|
|
"let g:nvim_tree_auto_resize = 0
|
|
"let g:nvim_tree_disable_netrw = 1
|
|
"let g:nvim_tree_hijack_netrw = 0
|
|
"let g:nvim_tree_add_trailing = 1
|
|
"let g:nvim_tree_group_empty = 1
|
|
"let g:nvim_tree_lsp_diagnostics = 1
|
|
"let g:nvim_tree_icon_padding = ' '
|
|
"let g:nvim_tree_symlink_arrow = ' >>'
|
|
"let g:nvim_tree_special_files = { 'README.md': 1, 'Makefile': 1, 'MAKEFILE': 1 }
|
|
"let g:nvim_tree_show_icons = {
|
|
" \ 'git': 1,
|
|
" \ 'folders': 1,
|
|
" \ 'files': 1,
|
|
" \ 'folder_arrows': 0
|
|
" \ }
|
|
|