Merge branch 'jidbo-master'
This commit is contained in:
commit
632e75afc3
4 changed files with 93 additions and 52 deletions
122
.vimrc
122
.vimrc
|
@ -1,9 +1,3 @@
|
||||||
" if empty(glob("~/.vim/bundle/Vundle.vim"))
|
|
||||||
" silent !git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
|
|
||||||
" autocmd GUIEnter * PluginInstall
|
|
||||||
" \ source ~/.vimrc
|
|
||||||
" endif
|
|
||||||
|
|
||||||
set nocompatible " required
|
set nocompatible " required
|
||||||
filetype off " required
|
filetype off " required
|
||||||
|
|
||||||
|
@ -17,49 +11,52 @@ Plugin 'gmarik/Vundle.vim'
|
||||||
" add all your plugins here (note older versions of Vundle
|
" add all your plugins here (note older versions of Vundle
|
||||||
" used Bundle instead of Plugin)
|
" used Bundle instead of Plugin)
|
||||||
|
|
||||||
" Simply Fold
|
" USEFUL
|
||||||
Plugin 'tmhedberg/SimpylFold'
|
" comment plugin
|
||||||
|
Plugin 'tpope/vim-commentary'
|
||||||
|
|
||||||
" autodindent python
|
" close xml/html tags
|
||||||
Plugin 'vim-scripts/indentpython.vim'
|
Plugin 'docunext/closetag.vim'
|
||||||
|
|
||||||
" syntax highlighting
|
" WINDOW MANAGEMENT
|
||||||
Plugin 'vim-syntastic/syntastic'
|
" tmux navigator
|
||||||
|
Plugin 'christoomey/vim-tmux-navigator'
|
||||||
" pep8 checking
|
|
||||||
Plugin 'nvie/vim-flake8'
|
|
||||||
|
|
||||||
" jedi-vim
|
|
||||||
Plugin 'davidhalter/jedi-vim'
|
|
||||||
|
|
||||||
" winresizer
|
" winresizer
|
||||||
Plugin 'simeji/winresizer'
|
Plugin 'simeji/winresizer'
|
||||||
|
|
||||||
" search for files
|
" FILE MANAGEMENT
|
||||||
Plugin 'ctrlpvim/ctrlp.vim'
|
|
||||||
|
|
||||||
" color schemes
|
|
||||||
Plugin 'flazz/vim-colorschemes'
|
|
||||||
|
|
||||||
" nert-tree
|
" nert-tree
|
||||||
Plugin 'scrooloose/nerdtree'
|
Plugin 'scrooloose/nerdtree'
|
||||||
|
|
||||||
" nerd-commenter
|
" fzf plugin
|
||||||
Plugin 'scrooloose/nerdcommenter'
|
Plugin 'junegunn/fzf.vim'
|
||||||
|
|
||||||
|
" GIT STUFF
|
||||||
" git
|
" git
|
||||||
Plugin 'tpope/vim-fugitive'
|
Plugin 'tpope/vim-fugitive'
|
||||||
|
|
||||||
" surround blocks
|
" vim gitgutter
|
||||||
Plugin 'tpope/vim-surround'
|
Plugin 'airblade/vim-gitgutter'
|
||||||
|
|
||||||
" latex
|
" COLORS
|
||||||
Plugin 'lervag/vimtex'
|
" color schemes
|
||||||
|
Plugin 'flazz/vim-colorschemes'
|
||||||
|
|
||||||
" powerline
|
" powerline
|
||||||
Plugin 'vim-airline/vim-airline'
|
Plugin 'vim-airline/vim-airline'
|
||||||
Plugin 'vim-airline/vim-airline-themes'
|
Plugin 'vim-airline/vim-airline-themes'
|
||||||
|
|
||||||
|
" LANGUAGE SUPPORT
|
||||||
|
" vim ale for interaction with language servers
|
||||||
|
Plugin 'w0rp/ale'
|
||||||
|
|
||||||
|
" language packs
|
||||||
|
Plugin 'sheerun/vim-polyglot'
|
||||||
|
|
||||||
|
" latex
|
||||||
|
Plugin 'lervag/vimtex'
|
||||||
|
|
||||||
" promela syntax highlighting
|
" promela syntax highlighting
|
||||||
Plugin 'vim-scripts/promela.vim'
|
Plugin 'vim-scripts/promela.vim'
|
||||||
|
|
||||||
|
@ -70,8 +67,6 @@ filetype plugin indent on " required
|
||||||
" syntax
|
" syntax
|
||||||
syntax on
|
syntax on
|
||||||
colorscheme Benokai
|
colorscheme Benokai
|
||||||
let g:airline_theme='luna'
|
|
||||||
let python_highlight_all=1
|
|
||||||
let mapleader=" "
|
let mapleader=" "
|
||||||
|
|
||||||
" random settings
|
" random settings
|
||||||
|
@ -84,6 +79,7 @@ set virtualedit=block
|
||||||
set scrolloff=1
|
set scrolloff=1
|
||||||
set wildmenu
|
set wildmenu
|
||||||
set term=screen-256color
|
set term=screen-256color
|
||||||
|
set autoread
|
||||||
|
|
||||||
" tabs and line wrap
|
" tabs and line wrap
|
||||||
set tabstop=4
|
set tabstop=4
|
||||||
|
@ -100,6 +96,11 @@ set incsearch
|
||||||
set hlsearch
|
set hlsearch
|
||||||
set smartcase
|
set smartcase
|
||||||
|
|
||||||
|
" Disable Backup and Swap files
|
||||||
|
set noswapfile
|
||||||
|
set nobackup
|
||||||
|
set nowritebackup
|
||||||
|
|
||||||
" setup split
|
" setup split
|
||||||
set splitbelow
|
set splitbelow
|
||||||
set splitright
|
set splitright
|
||||||
|
@ -111,16 +112,16 @@ nnoremap <leader>l <C-W><C-L>
|
||||||
nnoremap <leader>h <C-W><C-H>
|
nnoremap <leader>h <C-W><C-H>
|
||||||
|
|
||||||
" tabs
|
" tabs
|
||||||
nnoremap <leader>t :tabnew<CR>
|
nnoremap <leader>t :tabnew<CR>
|
||||||
nnoremap <leader>u gT
|
nnoremap <C-n> gT
|
||||||
nnoremap <leader>i gt
|
nnoremap <C-p> gt
|
||||||
|
|
||||||
" Enable folding
|
" Enable folding
|
||||||
set foldmethod=indent
|
set foldmethod=indent
|
||||||
set foldlevel=99
|
set foldlevel=99
|
||||||
|
|
||||||
" remap code folding
|
" remap code folding
|
||||||
nnoremap <leader>f za
|
nnoremap <leader>g za
|
||||||
|
|
||||||
" html css js indents
|
" html css js indents
|
||||||
au BufNewFile,BufRead *.js, *.html, *.css
|
au BufNewFile,BufRead *.js, *.html, *.css
|
||||||
|
@ -131,22 +132,41 @@ au BufNewFile,BufRead *.js, *.html, *.css
|
||||||
" PLUGIN SETTINGS
|
" PLUGIN SETTINGS
|
||||||
" nerd tree setup
|
" nerd tree setup
|
||||||
let NERDTreeIgnore=['\.pyc$', '\~$'] "ignore files in NERDTree
|
let NERDTreeIgnore=['\.pyc$', '\~$'] "ignore files in NERDTree
|
||||||
map <leader>n :NERDTreeToggle<CR>
|
map <leader>e :NERDTreeToggle<CR>
|
||||||
|
|
||||||
" ctrl-p setup
|
" airline setup
|
||||||
let g:ctrlp_working_path_mode = 'ra'
|
|
||||||
let g:ctrlp_custom_ignore = {
|
|
||||||
\ 'dir': '\v[\/](\.(git|hg|svn))?(venv)?$',
|
|
||||||
\ 'file': '\v\.(exe|so|dll)$',
|
|
||||||
\ 'link': 'some_bad_symbolic_links',
|
|
||||||
\ }
|
|
||||||
|
|
||||||
" see docstrings for folded code
|
|
||||||
let g:SimpylFold_docstring_preview=1
|
|
||||||
|
|
||||||
" airline tabs
|
|
||||||
let g:airline#extensions#tabline#enabled = 1
|
let g:airline#extensions#tabline#enabled = 1
|
||||||
let g:airline#extensions#tabline#formatter = 'unique_tail_improved'
|
let g:airline#extensions#tabline#formatter = 'unique_tail_improved'
|
||||||
|
let g:airline_theme='solarized'
|
||||||
|
let g:airline_solarized_bg='dark'
|
||||||
|
let g:airline_powerline_fonts = 1
|
||||||
|
|
||||||
" nerd-commenter setup
|
" gitgutter setup
|
||||||
let g:NERDSpaceDelims = 1
|
let g:gitgutter_sign_added = '∙'
|
||||||
|
let g:gitgutter_sign_modified = '∙'
|
||||||
|
let g:gitgutter_sign_removed = '∙'
|
||||||
|
let g:gitgutter_sign_modified_removed = '∙'
|
||||||
|
nmap ]g :GitGutterNextHunk<CR>
|
||||||
|
nmap [g :GitGutterPrevHunk<CR>
|
||||||
|
augroup VimDiff
|
||||||
|
autocmd!
|
||||||
|
autocmd VimEnter,FilterWritePre * if &diff | GitGutterDisable | endif
|
||||||
|
augroup END
|
||||||
|
|
||||||
|
" fzf setup
|
||||||
|
nmap <C-z> :Buffers<CR>
|
||||||
|
nmap <Leader>f :Files<CR>
|
||||||
|
let g:fzf_buffers_jump = 1
|
||||||
|
|
||||||
|
" vim-ale setup
|
||||||
|
let g:ale_completion_enabled = 1
|
||||||
|
let g:ale_lint_on_text_changed = 'never'
|
||||||
|
let g:ale_fixers = {
|
||||||
|
\ '*': ['trim_whitespace'],
|
||||||
|
\ 'python': ['autopep8']
|
||||||
|
\ }
|
||||||
|
nmap <Leader>d :ALEGoToDefinition<CR>
|
||||||
|
nmap <Leader>r :ALEFindReferences<CR>
|
||||||
|
nmap <Leader>b :ALEFix<CR>
|
||||||
|
nnoremap <space>l :lnext<CR>
|
||||||
|
nnoremap <space>p :lprevious<CR>
|
||||||
|
|
12
.zshrc
12
.zshrc
|
@ -6,7 +6,7 @@ export ZSH="$HOME/.oh-my-zsh"
|
||||||
# Set name of the theme to load. Optionally, if you set this to "random"
|
# Set name of the theme to load. Optionally, if you set this to "random"
|
||||||
# it'll load a random theme each time that oh-my-zsh is loaded.
|
# it'll load a random theme each time that oh-my-zsh is loaded.
|
||||||
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
|
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
|
||||||
ZSH_THEME="agnoster"
|
ZSH_THEME="robbyrussell"
|
||||||
|
|
||||||
# Set list of themes to load
|
# Set list of themes to load
|
||||||
# Setting this variable when ZSH_THEME=random
|
# Setting this variable when ZSH_THEME=random
|
||||||
|
@ -66,6 +66,7 @@ plugins=(
|
||||||
dirhistory
|
dirhistory
|
||||||
gradle
|
gradle
|
||||||
per-directory-history
|
per-directory-history
|
||||||
|
fzf
|
||||||
)
|
)
|
||||||
|
|
||||||
source $ZSH/oh-my-zsh.sh
|
source $ZSH/oh-my-zsh.sh
|
||||||
|
@ -90,6 +91,9 @@ source $ZSH/oh-my-zsh.sh
|
||||||
# ssh
|
# ssh
|
||||||
# export SSH_KEY_PATH="~/.ssh/rsa_id"
|
# export SSH_KEY_PATH="~/.ssh/rsa_id"
|
||||||
|
|
||||||
|
# Set vim as default editor
|
||||||
|
export EDITOR='vim'
|
||||||
|
|
||||||
# Set personal aliases, overriding those provided by oh-my-zsh libs,
|
# Set personal aliases, overriding those provided by oh-my-zsh libs,
|
||||||
# plugins, and themes. Aliases can be placed here, though oh-my-zsh
|
# plugins, and themes. Aliases can be placed here, though oh-my-zsh
|
||||||
# users are encouraged to define aliases within the ZSH_CUSTOM folder.
|
# users are encouraged to define aliases within the ZSH_CUSTOM folder.
|
||||||
|
@ -110,6 +114,12 @@ alias la='ls -la'
|
||||||
if [ -f ~/.dotfiles/.localcommands ]; then
|
if [ -f ~/.dotfiles/.localcommands ]; then
|
||||||
source ~/.dotfiles/.localcommands
|
source ~/.dotfiles/.localcommands
|
||||||
fi
|
fi
|
||||||
|
# Tmuxinator autocomplete
|
||||||
|
if [ -f ~/.bin/tmuxinator.zsh ]; then
|
||||||
|
source ~/.bin/tmuxinator.zsh
|
||||||
|
fi
|
||||||
|
|
||||||
|
export PATH="$PATH:$(ruby -e 'print Gem.user_dir')/bin"
|
||||||
|
|
||||||
# Tmuxinator autocomplete
|
# Tmuxinator autocomplete
|
||||||
if [ -f ~/.bin/tmuxinator.zsh ]; then
|
if [ -f ~/.bin/tmuxinator.zsh ]; then
|
||||||
|
|
1
setup.sh
1
setup.sh
|
@ -28,6 +28,7 @@ ln -s ~/.dotfiles/.vim ~/.vim
|
||||||
ln -s ~/.dotfiles/tmux.conf ~/.tmux.conf
|
ln -s ~/.dotfiles/tmux.conf ~/.tmux.conf
|
||||||
ln -s ~/.dotfiles/.atom ~/.atom
|
ln -s ~/.dotfiles/.atom ~/.atom
|
||||||
|
|
||||||
|
|
||||||
# install vundle
|
# install vundle
|
||||||
if ! [ -d ~/.vim/bundle/Vundle.vim ]; then
|
if ! [ -d ~/.vim/bundle/Vundle.vim ]; then
|
||||||
echo '[INFO] Installing Vundle...'
|
echo '[INFO] Installing Vundle...'
|
||||||
|
|
10
tmux.conf
10
tmux.conf
|
@ -2,6 +2,16 @@
|
||||||
|
|
||||||
# set vi keys
|
# set vi keys
|
||||||
set-window-option -g mode-keys vi
|
set-window-option -g mode-keys vi
|
||||||
|
is_vim="ps -o state= -o comm= -t '#{pane_tty}' \
|
||||||
|
| grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
|
||||||
|
bind-key -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
|
||||||
|
bind-key -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D"
|
||||||
|
bind-key -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U"
|
||||||
|
bind-key -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R"
|
||||||
|
bind-key -T copy-mode-vi C-h select-pane -L
|
||||||
|
bind-key -T copy-mode-vi C-j select-pane -D
|
||||||
|
bind-key -T copy-mode-vi C-k select-pane -U
|
||||||
|
bind-key -T copy-mode-vi C-l select-pane -R
|
||||||
|
|
||||||
# default statusbar colors
|
# default statusbar colors
|
||||||
set-option -g status-bg black #base02
|
set-option -g status-bg black #base02
|
||||||
|
|
Loading…
Add table
Reference in a new issue