60 lines
1.3 KiB
VimL
60 lines
1.3 KiB
VimL
set showmatch " show matching
|
|
set ignorecase " case insensitive
|
|
set mouse=v " middle-click paste
|
|
|
|
" search: highlight, incremental
|
|
set hlsearch
|
|
set incsearch
|
|
|
|
set tabstop=4
|
|
set softtabstop=4
|
|
set expandtab
|
|
set shiftwidth=4
|
|
set autoindent
|
|
|
|
set number
|
|
|
|
set wildmode=longest,list
|
|
|
|
set cc=80
|
|
filetype plugin indent on
|
|
syntax on
|
|
set mouse=a " enable mouse click
|
|
set clipboard=unnamedplus " using system clipboard
|
|
|
|
filetype plugin on
|
|
set cursorline " highlight current cursorline
|
|
set ttyfast " speed up scrolling
|
|
set backupdir=~/.cache/nvim
|
|
|
|
let data_dir = has('nvim') ? stdpath('data') . '/site' : '~/.vim'
|
|
if empty(glob(data_dir . '/autoload/plug.vim'))
|
|
silent execute '!curl -fLo '.data_dir.'/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
|
|
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
|
|
endif
|
|
|
|
call plug#begin(stdpath('data') . '/plugged')
|
|
|
|
Plug 'nvim-lua/plenary.nvim'
|
|
Plug 'TimUntersberger/neogit'
|
|
|
|
Plug 'tpope/vim-fugitive'
|
|
|
|
Plug 'editorconfig/editorconfig-vim'
|
|
|
|
Plug 'wakatime/vim-wakatime'
|
|
|
|
call plug#end()
|
|
|
|
lua <<EOF
|
|
local neogit = require('neogit')
|
|
neogit.setup {
|
|
disable_commit_confirmation = true,
|
|
disable_insert_on_commit = true
|
|
}
|
|
EOF
|
|
:nmap <C-x>g :Neogit<CR>
|
|
|
|
" no ex mode
|
|
nnoremap Q <Nop>
|