Migrated to plug for bundle management. Moved vim installation intno vimrc
This commit is contained in:
parent
570e726884
commit
5074e3b835
@ -11,18 +11,9 @@ while getopts ":hbsdclw" VALUE "$@"; do
|
||||
echo " -w Installs wemux [requires vim]"
|
||||
fi
|
||||
if [ "$VALUE" = "b" ] ; then
|
||||
mkdir -p ~/.vim/plugin/
|
||||
mkdir -p ~/.vim/backup/
|
||||
mkdir -p ~/.vim/undo/
|
||||
mkdir -p ~/.vim/tmp/
|
||||
mkdir -p ~/.vim/bundle/
|
||||
mkdir -p ~/.vim/bundle/
|
||||
echo "Installing vim bundles"
|
||||
if [ ! -d ~/.vim/bundle/vundle/ ] ; then
|
||||
echo "Installing vundle"
|
||||
git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle
|
||||
fi
|
||||
vim +PluginClean +PluginInstall +qa
|
||||
rm ~/.vimrc
|
||||
ln -s $ABSPATH/vim/vimrc ~/.vimrc
|
||||
vim +"silent! call Initialize()" +q
|
||||
fi
|
||||
if [ "$VALUE" = "s" ] ; then
|
||||
if [ "$(uname)" != "Darwin" ]; then
|
||||
@ -51,14 +42,13 @@ while getopts ":hbsdclw" VALUE "$@"; do
|
||||
if [ "$VALUE" = "c" ] ; then
|
||||
echo "Syncing config files"
|
||||
if which trash >/dev/null; then
|
||||
trash ~/.gitconfig ~/.vimrc ~/.vimperatorrc ~/.vimperator/colors/vimPgray.vimp ~/.bashrc ~/.pylintrc ~/.zshrc ~/.tmux.conf
|
||||
trash ~/.gitconfig ~/.vimperatorrc ~/.vimperator/colors/vimPgray.vimp ~/.bashrc ~/.pylintrc ~/.zshrc ~/.tmux.conf
|
||||
else
|
||||
rm ~/.gitconfig ~/.vimrc ~/.vimperatorrc ~/.vimperator/colors/vimPgray.vimp ~/.bashrc ~/.pylintrc ~/.zshrc ~/.tmux.conf
|
||||
rm ~/.gitconfig ~/.vimperatorrc ~/.vimperator/colors/vimPgray.vimp ~/.bashrc ~/.pylintrc ~/.zshrc ~/.tmux.conf
|
||||
fi
|
||||
# Install on all systems
|
||||
ln -s $ABSPATH/tmux/tmux.conf ~/.tmux.conf
|
||||
ln -s $ABSPATH/python/pylintrc ~/.pylintrc
|
||||
ln -s $ABSPATH/vim/vimrc ~/.vimrc
|
||||
ln -s $ABSPATH/vimperator/vimperatorrc ~/.vimperatorrc
|
||||
mkdir -p ~/.vimperator/colors
|
||||
ln -s $ABSPATH/vimperator/vimPgray.vimp ~/.vimperator/colors/vimPgray.vimp
|
||||
|
@ -3,4 +3,6 @@ LP_ENABLE_TIME=1
|
||||
LP_ENABLE_BATT=1
|
||||
LP_ENABLE_SSH_COLORS=1
|
||||
LP_USER_ALWAYS=0
|
||||
LP_ENABLE_OHMYGIT=1
|
||||
LP_ENABLE_BATT=1
|
||||
# vim: ft=sh:
|
||||
|
116
vim/vimrc
116
vim/vimrc
@ -226,102 +226,101 @@ inoremap <expr> <CR> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>"
|
||||
let loaded_matchit=1
|
||||
let g:UltiSnipsEditSplit="vertical"
|
||||
filetype off
|
||||
call vundle#rc()
|
||||
"Plugin 'Floobits/floobits-vim'
|
||||
"Plugin 'tsaleh/vim-matchit'
|
||||
"Plugin 'Shougo/neosnippet'
|
||||
"Plugin 'msanders/snipmate.vim'
|
||||
"Plugin 'vim-scripts/YankRing.vim'
|
||||
Plugin 'gmarik/vundle'
|
||||
"Required: manages all Plugins | https://github.com/gmarik/vundle
|
||||
Plugin 'Chiel92/vim-autoformat'
|
||||
call plug#begin('~/.vim/plugged')
|
||||
"Plug 'Floobits/floobits-vim'
|
||||
"Plug 'tsaleh/vim-matchit'
|
||||
"Plug 'Shougo/neosnippet'
|
||||
"Plug 'msanders/snipmate.vim'
|
||||
"Plug 'vim-scripts/YankRing.vim'
|
||||
Plug 'Chiel92/vim-autoformat'
|
||||
"Adds autoformat command | https://github.com/Chiel92/vim-autoformat
|
||||
Plugin 'tpope/vim-surround'
|
||||
Plug 'tpope/vim-surround'
|
||||
"Surround selection in ({\"' or HTML tags | https://github.com/tpope/vim-surround
|
||||
Plugin 'scrooloose/syntastic'
|
||||
Plug 'scrooloose/syntastic'
|
||||
"Syntax checker | https://github.com/scrooloose/syntastic
|
||||
"Plugin 'Shougo/neocomplcache.vim'
|
||||
"Plug 'Shougo/neocomplcache.vim'
|
||||
" "Tab complete everything | https://github.com/Shougo/neocomplcache.vim
|
||||
Plugin 'nathanaelkane/vim-indent-guides'
|
||||
Plug 'nathanaelkane/vim-indent-guides'
|
||||
"Indentation guides | https://github.com/nathanaelkane/vim-indent-guides
|
||||
Plugin 'elzr/vim-json'
|
||||
Plug 'elzr/vim-json'
|
||||
"JSON highlighting | https://github.com/elzr/vim-json
|
||||
Plugin 'groenewege/vim-less'
|
||||
Plug 'groenewege/vim-less'
|
||||
"LESS highlighting | https://github.com/groenewege/vim-less
|
||||
Plugin 'pangloss/vim-javascript'
|
||||
Plug 'pangloss/vim-javascript'
|
||||
"JS syntax and indentation | https://github.com/pangloss/vim-javascript
|
||||
Plugin 'briancollins/vim-jst'
|
||||
Plug 'briancollins/vim-jst'
|
||||
"Actually, I do not know what this does | https://github.com/briancollins/vim-jst
|
||||
Plugin 'kchmck/vim-coffee-script'
|
||||
Plug 'kchmck/vim-coffee-script'
|
||||
"Coffeescript syntax | https://github.com/kchmck/vim-coffee-script
|
||||
Plugin 'Lokaltog/powerline-fonts'
|
||||
Plug 'Lokaltog/powerline-fonts'
|
||||
"Better powerline fonts | https://github.com/Lokaltog/powerline-fonts
|
||||
Plugin 'bling/vim-airline'
|
||||
Plug 'bling/vim-airline'
|
||||
"Bottom status bar | https://github.com/bling/vim-airline
|
||||
Plugin 'terryma/vim-multiple-cursors'
|
||||
Plug 'terryma/vim-multiple-cursors'
|
||||
"Multicursor functionality like Coda | https://github.com/terryma/vim-multiple-cursors
|
||||
Plugin 'scrooloose/nerdtree'
|
||||
Plug 'scrooloose/nerdtree'
|
||||
"File browser | https://github.com/scrooloose/nerdtree
|
||||
Plugin 'altercation/vim-colors-solarized'
|
||||
Plug 'altercation/vim-colors-solarized'
|
||||
"Theme | https://github.com/altercation/vim-colors-solarized
|
||||
Plugin 'stonewareslord/vim-colors'
|
||||
Plug 'stonewareslord/vim-colors'
|
||||
"Theme pack | https://github.com/spf13/vim-colors
|
||||
Plugin 'spf13/PIV'
|
||||
Plug 'spf13/PIV'
|
||||
"PHP tools | https://github.com/spf13/PIV
|
||||
Plugin 'vim-scripts/AutoTag'
|
||||
Plug 'vim-scripts/AutoTag'
|
||||
"Generates taglist with ctags | https://github.com/vim-scripts/AutoTag
|
||||
Plugin 'Lokaltog/vim-easymotion'
|
||||
Plug 'Lokaltog/vim-easymotion'
|
||||
"Move around quickly in a document | https://github.com/Lokaltog/vim-easymotion
|
||||
Plugin 'sjl/gundo.vim'
|
||||
Plug 'sjl/gundo.vim'
|
||||
"Visual undo | https://github.com/sjl/gundo.vim
|
||||
Plugin 'tommcdo/vim-exchange'
|
||||
Plug 'tommcdo/vim-exchange'
|
||||
"Exchange two selections of text | https://github.com/tommcdo/vim-exchange
|
||||
Plugin 'tpope/vim-repeat'
|
||||
Plug 'tpope/vim-repeat'
|
||||
"Repeat last tpope command with . | https://github.com/tpope/vim-repeat
|
||||
Plugin 'tpope/vim-commentary'
|
||||
Plug 'tpope/vim-commentary'
|
||||
"Comment selection | https://github.com/tpope/vim-commentary
|
||||
Plugin 'vim-php/vim-php-refactoring'
|
||||
Plug 'vim-php/vim-php-refactoring'
|
||||
"PHP refactoring | https://github.com/vim-php/vim-php-refactoring
|
||||
Plugin 'tpope/vim-fugitive'
|
||||
Plug 'tpope/vim-fugitive'
|
||||
"Great Vim-Git compatibility | https://github.com/tpope/vim-fugitive
|
||||
Plugin 'tpope/vim-unimpaired'
|
||||
Plug 'tpope/vim-unimpaired'
|
||||
"Bracket shortcuts | https://github.com/tpope/vim-unimpaired
|
||||
Plugin 'kien/ctrlp.vim'
|
||||
Plug 'kien/ctrlp.vim'
|
||||
"Fuzzy file search | https://github.com/kien/ctrlp.vim
|
||||
Plugin 'tacahiroy/ctrlp-funky'
|
||||
Plug 'tacahiroy/ctrlp-funky'
|
||||
"Fuzzy function search | https://github.com/tacahiroy/ctrlp-funky
|
||||
Plugin 'godlygeek/tabular'
|
||||
Plug 'godlygeek/tabular'
|
||||
"Quickly make tables in vim | https://github.com/godlygeek/tabular
|
||||
Plugin 'tpope/vim-abolish'
|
||||
Plug 'tpope/vim-abolish'
|
||||
"Better abbrivation | https://github.com/tpope/vim-abolish
|
||||
Plugin 'godlygeek/csapprox'
|
||||
Plug 'godlygeek/csapprox'
|
||||
"256 color vim in terminal | https://github.com/godlygeek/csapprox
|
||||
Plugin 'sirver/UltiSnips'
|
||||
Plug 'sirver/UltiSnips'
|
||||
"Adds snippets | https://github.com/sirver/UltiSnips
|
||||
Plugin 'honza/vim-snippets'
|
||||
Plug 'honza/vim-snippets'
|
||||
"More snippets | https://github.com/honza/vim-snippets
|
||||
Plugin 'Shougo/neocomplete.vim'
|
||||
Plug 'Shougo/neocomplete.vim'
|
||||
"Autocompletes | https://github.com/Shougo/neocomplete.vim
|
||||
Plugin 'othree/eregex.vim'
|
||||
Plug 'othree/eregex.vim'
|
||||
"Real regexes in vim | https://github.com/othree/eregex.vim
|
||||
Plugin 'vim-scripts/sessionman.vim'
|
||||
Plug 'vim-scripts/sessionman.vim'
|
||||
"Session manager | https://github.com/vim-scripts/sessionman.vim
|
||||
Plugin 'mattn/flappyvird-vim'
|
||||
Plug 'mattn/flappyvird-vim'
|
||||
"The amazing Flappy Bird game | https://github.com/mattn/flappyvird-vim
|
||||
Plugin 'morhetz/gruvbox'
|
||||
Plug 'morhetz/gruvbox'
|
||||
"Colorscheme | https://github.com/morhetz/gruvbox
|
||||
Plugin 'superbrothers/vim-vimperator'
|
||||
Plug 'superbrothers/vim-vimperator'
|
||||
"Vimperator for vim | https://github.com/superbrothers/vim-vimperator
|
||||
Plugin 'Rykka/colorv.vim'
|
||||
Plug 'Rykka/colorv.vim'
|
||||
"Color selection in vim | https://github.com/Rykka/colorv.vim
|
||||
"Plugin 'Townk/vim-autoclose'
|
||||
"Plug 'Townk/vim-autoclose'
|
||||
" "Autoclose brackets | https://github.com/Townk/vim-autoclose
|
||||
Plugin 'mhinz/vim-signify'
|
||||
Plug 'mhinz/vim-signify'
|
||||
"Git information inline | https://github.com/mhinz/vim-signify
|
||||
Plugin 'jamessan/vim-gnupg'
|
||||
Plug 'jamessan/vim-gnupg'
|
||||
" | https://github.com/jamessan/vim-gnupg
|
||||
" |
|
||||
"DO NOT DELETE LINE ABOVE OR \bun WILL BREAK
|
||||
call plug#end()
|
||||
filetype plugin indent on
|
||||
if exists("+undofile")
|
||||
if isdirectory($HOME . '/.vim/undo')==0
|
||||
@ -345,8 +344,6 @@ augroup vimrcEx
|
||||
augroup END
|
||||
if has('gui_running')
|
||||
set guioptions-=T
|
||||
set lines=40
|
||||
"colorscheme fruity
|
||||
else
|
||||
if &term=='xterm' || &term=='screen'
|
||||
set t_Co=256
|
||||
@ -355,3 +352,16 @@ else
|
||||
endif
|
||||
silent! colorscheme fruity
|
||||
nnoremap <Leader>W :%s/\s\+$//<cr>:let @/=''<cr>
|
||||
function! Initialize()
|
||||
silent !mkdir -p ~/.vim/autoload
|
||||
silent !mkdir -p ~/.vim/plugin
|
||||
silent !mkdir -p ~/.vim/backup
|
||||
silent !mkdir -p ~/.vim/undo
|
||||
silent !mkdir -p ~/.vim/tmp
|
||||
if empty(glob("~/.vim/autoload/plug.vim"))
|
||||
!curl -fLo ~/.vim/autoload/plug.vim https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
|
||||
endif
|
||||
silent! so ~/.vimrc
|
||||
silent! PlugInstall
|
||||
q
|
||||
endfunction
|
||||
|
Loading…
Reference in New Issue
Block a user