From 87d6b0b4ee666982251ab00389c403c56f9fd870 Mon Sep 17 00:00:00 2001 From: Alexander Karle Date: Mon, 23 Apr 2018 00:31:57 -0400 Subject: [PATCH] Minor vim tweaks for plugins and colors --- vim/ftplugin/html.vim | 4 ++++ vim/plugins.vim | 8 ++++++-- vim/pluginsettings.vim | 2 +- vim/theme.vim | 24 ++++++++++-------------- vim/vimrc | 2 -- 5 files changed, 21 insertions(+), 19 deletions(-) create mode 100644 vim/ftplugin/html.vim diff --git a/vim/ftplugin/html.vim b/vim/ftplugin/html.vim new file mode 100644 index 0000000..20e40cc --- /dev/null +++ b/vim/ftplugin/html.vim @@ -0,0 +1,4 @@ +" 2 spaces +setlocal tabstop=2 +setlocal softtabstop=2 +setlocal shiftwidth=2 diff --git a/vim/plugins.vim b/vim/plugins.vim index 2a7b6aa..6049a8e 100644 --- a/vim/plugins.vim +++ b/vim/plugins.vim @@ -2,12 +2,16 @@ call plug#begin('~/.vim/bundle') " Colorscheme -Plug 'rakr/vim-one' +Plug 'morhetz/gruvbox' + +" Extra syntax files +Plug 'octol/vim-cpp-enhanced-highlight' +Plug 'posva/vim-vue' " Plug nerdtree for tree package explorer Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' } -" Airline = status bar for vime +" Airline = status bar for vim Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline-themes' diff --git a/vim/pluginsettings.vim b/vim/pluginsettings.vim index b18ee0c..51bbf40 100644 --- a/vim/pluginsettings.vim +++ b/vim/pluginsettings.vim @@ -17,4 +17,4 @@ let g:vimtex_view_method='skim' "for airline status bar -- need to include font let g:airline_powerline_fonts = 0 -let g:airline_theme = 'onedark' +let g:airline_theme = 'gruvbox' diff --git a/vim/theme.vim b/vim/theme.vim index f25fc5d..5ea2a79 100644 --- a/vim/theme.vim +++ b/vim/theme.vim @@ -11,25 +11,18 @@ if(has('autocmd')) endif " COLORSCHEME -" use iterm profiles to determine background -if $ITERM_PROFILE=='light_background' - set background=light -else - set background=dark -endif - " if can use truecolor, do if (has("termguicolors")) - " load colorscheme if plugins installed - if filereadable(expand("~/.vim/bundle/vim-one/colors/one.vim")) - let g:one_allow_italics = 1 + if filereadable(expand("~/.vim/bundle/gruvbox/colors/gruvbox.vim")) + let g:gruvbox_italic = 1 set termguicolors - colorscheme one - " reverse one-dark's fold colors - highlight Folded guibg=#282c34 guifg=#5c6370 + colorscheme gruvbox + "let g:gruvbox_contrast_dark='hard' " make pythonSelf red not grey - highlight pythonSelf ctermfg=168 guifg=#e06c75 + highlight link pythonSelf GruvboxBlue + " make functions no longer bold + " hi! link Function GruvboxGreen endif " Needed for termgui in tmux--&term begins w screen-... @@ -41,6 +34,9 @@ if (has("termguicolors")) endif endif +set background=dark " seems to need to be after gruvbox + + " Allow cursor to change shape " https://stackoverflow.com/questions/6488683/how-do-i-change-the-vim-cursor-in-insert-normal-mode/42118416#42118416 let &t_SI = "\e[6 q" diff --git a/vim/vimrc b/vim/vimrc index 45da42c..61ca6d1 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -22,10 +22,8 @@ set backspace=indent,eol,start set hlsearch set incsearch -set rtp+=/usr/local/opt/fzf filetype plugin indent on - " OTHER " Link clipboard to mac set clipboard=unnamed -- libgit2 0.28.4