Browse Source

Update vim configs

master
arnaucube 3 years ago
parent
commit
9270f1dd50
5 changed files with 63 additions and 49 deletions
  1. +2
    -41
      .vimrc
  2. +7
    -0
      README.md
  3. +12
    -8
      init.vim
  4. +1
    -0
      install-new-server.sh
  5. +41
    -0
      vimconfigbase.vim

+ 2
- 41
.vimrc

@ -1,3 +1,5 @@
source ~/vimconfigbase.vim
call plug#begin(expand('~/.vim/plugged'))
Plug 'morhetz/gruvbox'
@ -6,47 +8,6 @@ Plug 'morhetz/gruvbox'
call plug#end()
" visual
syntax on
set ruler
set number
set title
set titlestring=nvim-%F
set t_Co=256
set cursorline
set background=dark " for the dark version
" abbreviations
cnoreabbrev W! w!
cnoreabbrev Q! q!
cnoreabbrev Qall! qall!
cnoreabbrev Wq wq
cnoreabbrev Wa wa
cnoreabbrev wQ wq
cnoreabbrev WQ wq
cnoreabbrev W w
cnoreabbrev Q q
cnoreabbrev Qall qall
cnoreabbrev Qa qa
"" Switching windows
noremap <C-j> <C-w>j
noremap <C-k> <C-w>k
noremap <C-l> <C-w>l
noremap <C-h> <C-w>h
"" esc mapping
inoremap jk <ESC>
tnoremap jk <C-\><C-n>
" scroll
set scrolloff=5 " keep at least 5 lines above/below
set sidescrolloff=5 " keep at least 5 lines left/right
colorscheme torte
set background=dark
hi statusline ctermfg=234 ctermbg=250
hi LineNr ctermfg=246
colorscheme gruvbox

+ 7
- 0
README.md

@ -24,7 +24,14 @@ alias lst='exa -l -snew'
---
- Vim: `.vimrc`
- put `vimconfigbase.vim` into `~/`
- put `.vimrc` into `~/`
- install https://github.com/junegunn/vim-plug
- inside vim, execute: `:PlugInstall`
- NeoVim: `init.vim`
- put `vimconfigbase.vim` into `~/`
- in `.config/nvim/init.vim`
- install https://github.com/junegunn/vim-plug
- inside neovim, execute: `:PlugInstall`

+ 12
- 8
init.vim

@ -1,4 +1,4 @@
source ~/.vimrc
source ~/vimconfigbase.vim
call plug#begin(expand('~/.config/nvim/plugged'))
@ -26,6 +26,9 @@ Plug 'majutsushi/tagbar'
" rainbow parentheses
Plug 'luochen1990/rainbow'
" git
Plug 'tpope/vim-fugitive'
" go
Plug 'fatih/vim-go' " Amazing combination of features.
Plug 'godoctor/godoctor.vim' " Some refactoring tools
@ -48,17 +51,18 @@ Plug 'tomlion/vim-solidity'
" circom
Plug 'iden3/vim-circom-syntax'
" deoplete
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
Plug 'zchee/deoplete-go', {'build': {'unix': 'make'}}
" neosnippet with deoplete
Plug 'Shougo/neosnippet.vim'
Plug 'Shougo/neosnippet-snippets'
"
" " deoplete
" Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
" Plug 'zchee/deoplete-go', {'build': {'unix': 'make'}}
" " neosnippet with deoplete
" Plug 'Shougo/neosnippet.vim'
" Plug 'Shougo/neosnippet-snippets'
" automatically adjust shiftwidth and expand tab based on current file
Plug 'tpope/vim-sleuth'
let g:deoplete#enable_at_startup = 1
" let g:deoplete#enable_at_startup = 1
" Plugin deoplete neosnippet key-mappings.
" Note: It must be "imap" and "smap". It uses <Plug> mappings.
imap <C-k> <Plug>(neosnippet_expand_or_jump)

+ 1
- 0
install-new-server.sh

@ -13,6 +13,7 @@ cp ./.tmux.conf ~/.tmux.conf
# vim
echo "setting vim config"
cp ./.vimrc ~/.vimrc
cp ./vimconfigbase.vim ~/vimconfigbase.vim
# neovim
echo "installing neovim"

+ 41
- 0
vimconfigbase.vim

@ -0,0 +1,41 @@
" visual
syntax on
set ruler
set number
set title
set titlestring=nvim-%F
set t_Co=256
set cursorline
set background=dark " for the dark version
" abbreviations
cnoreabbrev W! w!
cnoreabbrev Q! q!
cnoreabbrev Qall! qall!
cnoreabbrev Wq wq
cnoreabbrev Wa wa
cnoreabbrev wQ wq
cnoreabbrev WQ wq
cnoreabbrev W w
cnoreabbrev Q q
cnoreabbrev Qall qall
cnoreabbrev Qa qa
"" Switching windows
noremap <C-j> <C-w>j
noremap <C-k> <C-w>k
noremap <C-l> <C-w>l
noremap <C-h> <C-w>h
"" esc mapping
inoremap jk <ESC>
tnoremap jk <C-\><C-n>
" scroll
set scrolloff=5 " keep at least 5 lines above/below
set sidescrolloff=5 " keep at least 5 lines left/right
" colorscheme torte
set background=dark
hi statusline ctermfg=234 ctermbg=250
hi LineNr ctermfg=246

Loading…
Cancel
Save