more changes
This commit is contained in:
@@ -12,18 +12,20 @@ if(have_plug)
|
||||
call plug#begin(vim_files . '/plugged')
|
||||
|
||||
Plug 'tpope/vim-sensible' " Sensible defaults for vim
|
||||
Plug 'w0ng/vim-hybrid' " Hybrid colorscheme
|
||||
Plug 'vim-airline/vim-airline' " Status bar
|
||||
Plug 'vim-airline/vim-airline-themes' " Status bar themes
|
||||
Plug 'ivyl/vim-bling' " blink search results
|
||||
|
||||
Plug 'ctrlpvim/ctrlp.vim' " Fuzzy search
|
||||
Plug 'editorconfig/editorconfig-vim' " EditorConfig.org support
|
||||
Plug 'ivyl/vim-bling' " blink search results
|
||||
Plug 'rking/ag.vim' " Silver Searcher Support
|
||||
Plug 'tacahiroy/ctrlp-funky' " Fuzzy in-buffer search
|
||||
Plug 'tommcdo/vim-lion' " Align stuff
|
||||
Plug 'tpope/vim-commentary' " Commenting
|
||||
Plug 'tpope/vim-fugitive' " Work with git repos
|
||||
Plug 'tpope/vim-surround' " Surround with quotes
|
||||
Plug 'rking/ag.vim' " Silver Searcher Support
|
||||
Plug 'tpope/vim-commentary' " Commenting
|
||||
" Plug 'vimwiki/vimwiki' " http://vimwiki.github.io/
|
||||
Plug 'vim-airline/vim-airline' " Status bar
|
||||
Plug 'vim-airline/vim-airline-themes' " Status bar themes
|
||||
Plug 'vimwiki/vimwiki' " http://vimwiki.github.io/
|
||||
Plug 'w0ng/vim-hybrid' " Hybrid colorscheme
|
||||
|
||||
" Language
|
||||
if executable('rails')
|
||||
@@ -37,6 +39,8 @@ if(have_plug)
|
||||
Plug 'quramy/vim-js-pretty-template' " Syntax highlight inside template strings
|
||||
Plug 'quramy/tsuquyomi' " Language server support for TypeScript
|
||||
|
||||
Plug 'heavenshell/vim-jsdoc' " Generate JSDoc comments
|
||||
|
||||
" Quality of life
|
||||
Plug 'edkolev/tmuxline.vim'
|
||||
|
||||
@@ -55,4 +59,10 @@ if(have_plug)
|
||||
endif
|
||||
endif
|
||||
|
||||
|
||||
let g:loaded_netrwPlugin = 1
|
||||
let g:airline_powerline_fonts = 1
|
||||
let g:airline#extensions#tabline#enabled = 1
|
||||
let g:airline#extensions#ale#enabled = 1
|
||||
let g:ale_sign_column_always = 1
|
||||
let g:ale_sign_error = ''
|
||||
let g:ale_sign_warning = ''
|
||||
|
||||
@@ -7,19 +7,19 @@ set visualbell
|
||||
set wildmode=full
|
||||
set background=dark
|
||||
silent! colorscheme hybrid
|
||||
let mapleader = '\' "Set <leader> before any key remapping
|
||||
" let mapleader = '\' "Set <leader> before any key remapping
|
||||
set hlsearch "highlight search results
|
||||
set ignorecase "ignore capitalization
|
||||
set smartcase
|
||||
set cursorline "highlight current line
|
||||
set listchars=tab:▸\ ,eol:¬
|
||||
"Invisible character colors
|
||||
highlight NonText guifg=#4a4a59
|
||||
highlight SpecialKey guifg=#4a4a59
|
||||
" highlight NonText guifg=#4a4a59
|
||||
" highlight SpecialKey guifg=#4a4a59
|
||||
"tab settings
|
||||
set shiftwidth=4
|
||||
set tabstop=4
|
||||
set expandtab
|
||||
set shiftwidth=4
|
||||
set softtabstop=4
|
||||
|
||||
set backspace=2 "set sane backspace behaviour
|
||||
|
||||
@@ -44,7 +44,7 @@ imap jk <Esc>
|
||||
set completeopt=longest,menu,menuone
|
||||
|
||||
" Stolen from maralla/dotvim
|
||||
function! EnsureExists(path)
|
||||
function! EnsureExists(path) abort
|
||||
if !isdirectory(expand(a:path))
|
||||
call mkdir(expand(a:path))
|
||||
endif
|
||||
|
||||
@@ -1,36 +1,32 @@
|
||||
"open config with \r
|
||||
nmap <leader>r :e $MYVIMRC<cr>
|
||||
nmap <silent><leader>w :up<cr>
|
||||
imap <silent><leader>w <Esc>:up<cr>a
|
||||
noremap <leader>r :edit $MYVIMRC<cr>
|
||||
noremap <silent><leader>w :update<cr>
|
||||
inoremap <silent><leader>w <Esc>:update<cr>a
|
||||
cmap w!! w !sudo tee % >/dev/null
|
||||
|
||||
cmap eh e %:h/
|
||||
|
||||
"Remove search highlight when <Esc> is pressed
|
||||
nnoremap <silent> <Esc><Esc> <Esc>:nohlsearch<CR><Esc>
|
||||
|
||||
"toggle whitespace
|
||||
nmap <leader>l :set list!<cr>
|
||||
noremap <leader>l :set list!<cr>
|
||||
|
||||
" noremap <silent> <leader>R :! echo reload \| nc -w 1 localhost 32000<cr><cr>
|
||||
noremap <silent><leader>R :! tmux send-keys -t right "up" C-m<cr><cr>
|
||||
|
||||
"press space in normal mode to center screen
|
||||
nmap <space> zz
|
||||
nmap <leader>] :bn<cr>
|
||||
nmap <leader>[ :bp<cr>
|
||||
nmap <leader>d :bd<cr>
|
||||
noremap <space> zz
|
||||
noremap <leader>] :bn<cr>
|
||||
noremap <leader>[ :bp<cr>
|
||||
noremap <leader>d :bd<cr>
|
||||
|
||||
if(exists("g:loaded_ale"))
|
||||
nmap <leader>e[ <Plug>(ale_previous_wrap)
|
||||
nmap <leader>e] <Plug>(ale_next_wrap)
|
||||
endif
|
||||
nmap <leader>e[ <Plug>(ale_previous_wrap)
|
||||
nmap <leader>e] <Plug>(ale_next_wrap)
|
||||
|
||||
let g:tsuquyomi_javascript_support = 1
|
||||
if(exists("g:loaded_tsuquyomi"))
|
||||
nmap <leader>p :echo tsuquyomi#hint()<cr>
|
||||
endif
|
||||
noremap <leader>p :echo tsuquyomi#hint()<cr>
|
||||
|
||||
let g:ctrlp_funky_syntax_highlight = 1
|
||||
if(exists("g:loaded_ctrlp_funky"))
|
||||
nnoremap <leader>f :CtrlPFunky<CR>
|
||||
endif
|
||||
nnoremap <leader>f :CtrlPFunky<CR>
|
||||
|
||||
|
||||
@@ -1,6 +1,18 @@
|
||||
if has("autocmd")
|
||||
filetype plugin indent on
|
||||
|
||||
augroup InvisibleCharsHighlight
|
||||
au!
|
||||
|
||||
autocmd ColorScheme * :call ResetColors()
|
||||
|
||||
function! ResetColors()
|
||||
"Invisible character colors
|
||||
highlight NonText guifg=#4a4a59
|
||||
highlight SpecialKey guifg=#4a4a59
|
||||
endfun
|
||||
augroup END
|
||||
|
||||
augroup CleanWhitespace
|
||||
au!
|
||||
autocmd BufWritePre * :call <SID>StripTrailingWhitespace()
|
||||
|
||||
Reference in New Issue
Block a user