dotfiles

Config files from my daily system
Index Commits Files Refs README
.config/.vimrc (1525B)
   1     call plug#begin('~/.vim/plugged')
   2 
   3     Plug 'preservim/nerdtree'
   4     Plug 'flw-cn/vim-nerdtree-l-open-h-close'
   5     Plug 'tpope/vim-commentary'
   6 
   7     call plug#end()
   8 
   9 " Basic settings
  10     syntax on
  11     set encoding=utf-8
  12     set tabstop=4
  13     set shiftwidth=4
  14     set incsearch
  15     set smartcase
  16     set smartindent
  17     set number
  18     set relativenumber
  19     set mouse=a
  20     set undofile
  21     set undodir=~/.config/nvim/undodir
  22     set clipboard=unnamedplus
  23     set nobackup
  24     set nowritebackup
  25     set noswapfile
  26     " set noshowmode
  27     " set backupdir=~/.config/nvim/tmp/backup
  28 
  29     " This fixs the delay in the cursor shape when switching mode
  30     set ttimeout
  31     set ttimeoutlen=1
  32     set listchars=tab:>-,trail:~,extends:>,precedes:<,space:.
  33     set ttyfast
  34 
  35     set fillchars+=vert:\ 
  36     highlight VertSplit cterm=NONE
  37 
  38     highlight ExtraWhitespace ctermbg=red guibg=red
  39 
  40 " Keys remap
  41     let mapleader = ' '
  42 
  43     " Open file tree;
  44     map <leader>f :NERDTreeToggle<CR>
  45 
  46     " Open current dir in NERDTree
  47     map <leader>r :NERDTreeFind<CR>
  48 
  49     " Disable ex-mode keybinding (type visual thing)
  50     map Q <NOP>
  51 
  52     " Improves indenting chunks of code with '<' '>' keys
  53     vnoremap < <gv
  54     vnoremap > >gv
  55 
  56     " Move between windows with Ctrl + hjkl
  57     noremap <C-h> <C-w>h
  58     noremap <C-j> <C-w>j
  59     noremap <C-k> <C-w>k
  60     noremap <C-l> <C-w>l
  61 
  62     " Change cursor shape with modes
  63     let &t_SI = "\<Esc>[6 q"
  64     let &t_SR = "\<Esc>[4 q"
  65     let &t_EI = "\<Esc>[2 q"
  66 
  67 " NetRW config
  68     let g:netrw_banner=0
  69     let g:netrw_winsize = 25
  70     let g:netrw_browse_split=2
  71     let g:netrw_altv=1
  72     let g:netrw_liststyle=3
  73     let g:netrwJ_list_hide=netrw_gitignore#Hide()