Skip to content

Instantly share code, notes, and snippets.

@Hecatoncheir
Last active April 16, 2018 11:47
Show Gist options
  • Select an option

  • Save Hecatoncheir/29d446802487dd410241b0c031cea802 to your computer and use it in GitHub Desktop.

Select an option

Save Hecatoncheir/29d446802487dd410241b0c031cea802 to your computer and use it in GitHub Desktop.
neovim
"dein Scripts-----------------------------
if &compatible
set nocompatible " Be iMproved
endif
" Required:
set runtimepath+=/home/vitaliy/.config/nvim/plugins/repos/github.com/Shougo/dein.vim
" Required:
if dein#load_state('/home/vitaliy/.config/nvim/plugins')
call dein#begin('/home/vitaliy/.config/nvim/plugins')
" Let dein manage dein
" Required:
call dein#add('/home/vitaliy/.config/nvim/plugins/repos/github.com/Shougo/dein.vim')
call dein#add('Shougo/deoplete.nvim')
if !has('nvim')
call dein#add('roxma/nvim-yarp')
call dein#add('roxma/vim-hug-neovim-rpc')
endif
"--- Main ---
call dein#add('dominikduda/vim_current_word')
call dein#add('Shougo/denite.nvim')
call dein#add('junegunn/fzf', { 'build': './install --all', 'merged': 0 })
call dein#add('junegunn/fzf.vim', { 'depends': 'fzf' })
"--- Nerd ---
call dein#add('scrooloose/nerdtree')
call dein#add('scrooloose/nerdcommenter')
call dein#add('Xuyuanp/nerdtree-git-plugin')
"--- Languages --
call dein#add('natebosch/vim-lsc')
call dein#add('dart-lang/dart-vim-plugin')
call dein#add('fatih/vim-go')
"Plug 'ap/vim-css-color'
call dein#add('KabbAmine/vCoolor.vim')
call dein#add('hail2u/vim-css3-syntax')
call dein#add('docker/docker')
call dein#add('fatih/vim-go')
"--- VCS ---
call dein#add('tpope/vim-fugitive')
call dein#add('sgur/vim-lazygutter')
call dein#add('vim-scripts/vcscommand.vim')
"--- Tags ---
call dein#add('mattn/emmet-vim')
call dein#add('majutsushi/tagbar')
"call dein#add('universal-ctags/ctags')
call dein#add('basilgor/vim-autotags')
"--- Themes ---
call dein#add('bling/vim-airline')
call dein#add('vim-airline/vim-airline-themes')
call dein#add('morhetz/gruvbox')
call dein#add('ryanoasis/vim-webdevicons')
" You can specify revision/branch/tag.
call dein#add('Shougo/deol.nvim', { 'rev': 'a1b5108fd' })
" Required:
call dein#end()
call dein#save_state()
endif
" Required:
filetype plugin indent on
syntax enable
" If you want to install not installed plugins on startup.
if dein#check_install()
call dein#install()
endif
"End dein Scripts-------------------------
let g:deoplete#enable_at_startup = 1
:tnoremap <Esc> <C-\><C-n>
"Base
set encoding=utf8
set background=dark
set spell
set linebreak
set noswapfile
set backspace=indent,eol,start
set laststatus=2
set number
set incsearch
set hlsearch
set ignorecase
set smartcase
set termencoding=utf8
set nocompatible
set ruler
set showcmd
set foldenable
set foldlevel=100
set foldmethod=indent
set noerrorbells visualbell t_vb=
set t_Co=256
set ch=1
set autoindent
set wrap
set expandtab
set shiftwidth=2
set softtabstop=2
set tabstop=2
set smartindent
set showmatch
"set lines=55
"set columns=140
set iskeyword=@,48-57,_,192-255
set history=200
set langmap=рh,оj,лk,дl,РH,ОJ,ЛK,ДL
set smarttab
set title
set autoread
set breakindent
set cursorline
set autochdir
set spell spelllang=ru_yo
setlocal spell spelllang=ru_yo
nnoremap <c-p> :FZF<cr>
"Main
let NERDTreeShowHidden=1
let g:lsc_server_commands = {'dart': 'dart_language_server'}
set bg=dark
colorscheme gruvbox
"deoplete tab-complete
inoremap <expr><tab> pumvisible() ? "\<c-n>" : "\<tab>"
"Airline
let g:airline#extensions#tabline#enabled = 1
let g:airline_theme='tomorrow'
let g:airline_right_alt_sep = ''
let g:airline_right_sep = ''
let g:airline_left_alt_sep= ''
let g:airline_left_sep = ''
"Additional
"---------------------
function! JumpToCSS()
let id_pos = searchpos("id", "nb", line('.'))[1]
let class_pos = searchpos("class", "nb", line('.'))[1]
if class_pos > 0 || id_pos > 0
if class_pos < id_pos
execute ":vim '#".expand('<cword>')."' *_theme.html"
elseif class_pos > id_pos
execute ":vim '.".expand('<cword>')."' *_theme.html"
endif
endif
endfunction
nnoremap <leader>] :call JumpToCSS()
"---------------------
if !exists("g:tagbar_type_dart")
let g:tagbar_type_dart = {
\ 'ctagsbin' : 'pub',
\ 'ctagsargs' : ['global', 'run', 'dart_ctags:tags', '--skip-sort', '--line-numbers'],
\ 'ctagstype' : 'dart',
\ 'kinds' : [
\ 'c:classes',
\ 'f:function',
\ 'M:static method',
\ 'm:method',
\ 'i:field'
\ ]
\ }
endif
"---------------------
let g:lsc_auto_map = v:true
let g:lsc_auto_map = {
\ 'GoToDefinition': '<C-]>',
\ 'FindReferences': 'gr',
\ 'NextReference': '<C-n>',
\ 'PreviousReference': '<C-p>',
\ 'FindImplementations': 'gI',
\ 'FindCodeActions': 'ga',
\ 'DocumentSymbol': 'go',
\ 'WorkspaceSymbol': 'gS',
\ 'ShowHover': 'K',
\ 'Completion': 'completefunc',
\}
"---------------------
let g:fzf_colors =
\ { 'fg': ['fg', 'Comment'],
\ 'bg': ['bg', 'Normal'],
\ 'hl': ['fg', 'Comment'],
\ 'fg+': ['fg', 'CursorLine', 'CursorColumn', 'Normal'],
\ 'bg+': ['bg', 'CursorLine', 'CursorColumn'],
\ 'hl+': ['fg', 'Statement'],
\ 'info': ['fg', 'PreProc'],
\ 'border': ['fg', 'Ignore'],
\ 'prompt': ['fg', 'Conditional'],
\ 'pointer': ['fg', 'Exception'],
\ 'marker': ['fg', 'Keyword'],
\ 'spinner': ['fg', 'Label'],
\ 'header': ['fg', 'Comment'] }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment