Skip to content

Commit

Permalink
Fix warnings in vimrc, cleanup tmux.conf and zshrc
Browse files Browse the repository at this point in the history
Signed-off-by: Tomas Slusny <[email protected]>
  • Loading branch information
deathbeam committed Jan 23, 2017
1 parent 8b87675 commit cc1b484
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 51 deletions.
42 changes: 10 additions & 32 deletions dotfiles/tmux.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

# General {{{

# renumber windows sequentially after closing any of them
# Renumber windows sequentially after closing any of them
set -g renumber-windows on

# start window numbers at 1 to match keyboard order with tmux window order
# Start window numbers at 1 to match keyboard order with tmux window order
set -g base-index 1
set-window-option -g pane-base-index 1

Expand All @@ -22,7 +22,7 @@
set -g prefix C-Space
bind C-space send-prefix

# open new windows and tabs with current path
# Open new windows and tabs with current path
bind c new-window -c "#{pane_current_path}"
bind '"' split-window -h -c "#{pane_current_path}"
bind % split-window -v -c "#{pane_current_path}"
Expand Down Expand Up @@ -51,21 +51,17 @@

# User interface {{{

# improve colors
# Improve colors
set -g default-terminal 'screen-256color'

# disable annoying notifications
# Disable annoying notifications
set-option -g visual-bell off
set-option -g visual-silence off
set-option -g bell-action none

# Turn status line off
set -g status off

# }}}

# Style {{{

# Command bar
set -g message-command-bg "colour0"
set -g message-command-fg "colour7"
Expand All @@ -74,38 +70,20 @@
set -g pane-border-fg "colour19"
set -g pane-active-border-fg "colour4"

# Status line
set -g status-bg "colour18"
set -g status-fg "colour7"
set -g status-justify "left"
set -g status-attr "none"
set -g status-left-length "100"
set -g status-left-attr "none"
set -g status-right-length "100"
set -g status-right-attr "none"
setw -g window-status-bg "colour18"
setw -g window-status-fg "colour7"
setw -g window-status-attr "none"
setw -g window-status-separator ""
setw -g window-status-activity-bg "colour18"
setw -g window-status-activity-fg "colour4"
setw -g window-status-activity-attr "none"

set -g status-left "#[fg=colour18,bg=colour4,bold] #S #[fg=colour4,bg=colour18,nobold,nounderscore,noitalics]"
set -g status-right "#[fg=colour19,bg=colour18,nobold,nounderscore,noitalics]#[fg=colour7,bg=colour19] %Y-%m-%d | %H:%M #[fg=colour4,bg=colour19,nobold,nounderscore,noitalics]#[fg=colour18,bg=colour4] #h "
setw -g window-status-format "#[fg=colour7,bg=colour18] #I |#[fg=colour7,bg=colour18] #W "
setw -g window-status-current-format "#[fg=colour18,bg=colour19,nobold,nounderscore,noitalics]#[fg=colour7,bg=colour19] #I |#[fg=colour7,bg=colour19] #W #[fg=colour19,bg=colour18,nobold,nounderscore,noitalics]"

# }}}

# Plugins {{{

run-shell "$DOTHOME/lib/tmux/custom.tmux"
# Some sane default configuration
run-shell "$DOTHOME/lib/tmux/tmux-sensible/sensible.tmux"
run-shell "$DOTHOME/lib/tmux/vim-tmux-navigator/vim-tmux-navigator.tmux"

# Copy mode enhancements
run-shell "$DOTHOME/lib/tmux/tmux-yank/yank.tmux"
run-shell "$DOTHOME/lib/tmux/tmux-copycat/copycat.tmux"
run-shell "$DOTHOME/lib/tmux/tmux-open/open.tmux"

# Session save and restore stuff
set -g @resurrect-strategy-vim 'session'
set -g @resurrect-strategy-nvim 'session'
set -g @resurrect-capture-pane-contents 'on'
Expand Down
28 changes: 14 additions & 14 deletions dotfiles/vimrc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@

" General {{{
" Reset all auto commands
autocmd!
augroup VimRc
autocmd!
augroup END

" With a map leader it's possible to do extra key combinations
let mapleader = ' '
Expand Down Expand Up @@ -160,15 +162,13 @@
set list listchars=tab:→\ ,trail:·

" Automatically rebalance windows on vim resize
autocmd VimResized * :wincmd =
autocmd VimRc VimResized * :wincmd =

" use syntax complete if nothing else available
if has('autocmd') && exists('+omnifunc')
autocmd Filetype *
\ if &omnifunc == "" |
\ setlocal omnifunc=syntaxcomplete#Complete |
\ endif
endif
autocmd VimRc Filetype *
\ if &omnifunc == "" |
\ setlocal omnifunc=syntaxcomplete#Complete |
\ endif

" }}}

Expand All @@ -194,8 +194,8 @@
set synmaxcol=256

" Highlight 121th character in line
autocmd BufEnter * highlight ColorColumn ctermbg=darkred ctermfg=white
autocmd BufEnter * call matchadd('ColorColumn', '\%121v', 100) "set column nr
autocmd VimRc BufEnter * highlight ColorColumn ctermbg=darkred ctermfg=white
autocmd VimRc BufEnter * call matchadd('ColorColumn', '\%121v', 100) "set column nr

" }}}

Expand Down Expand Up @@ -237,7 +237,7 @@
" When editing a file, always jump to the last known cursor position.
" Don't do it when the position is invalid or when inside an event handler
" (happens when dropping a file on gvim).
autocmd BufReadPost *
autocmd VimRc BufReadPost *
\ if line("'\"") >= 1 && line("'\"") <= line("$") |
\ exe "normal! g`\"" |
\ endif
Expand All @@ -250,8 +250,8 @@
" Set extra options when running in GUI mode
set mouse=a
set guitablabel=%M\ %t
autocmd GUIEnter * set vb t_vb=
autocmd GUIEnter * set guioptions-=e
autocmd VimRc GUIEnter * set vb t_vb=
autocmd VimRc GUIEnter * set guioptions-=e

" Disable scrollbars (real hackers don't use scrollbars for navigation!)
set guioptions-=r
Expand Down Expand Up @@ -414,7 +414,7 @@
nnoremap <silent> <leader>gp :Git push<CR>
nnoremap <silent> <leader>gw :Gwrite<CR>
nnoremap <silent> <leader>gr :Gremove<CR>
autocmd BufReadPost fugitive://* set bufhidden=delete
autocmd VimRc BufReadPost fugitive://* set bufhidden=delete

" Eclim
let g:EclimCompletionMethod='omnifunc'
Expand Down
3 changes: 0 additions & 3 deletions dotfiles/zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,6 @@
eval "$($DOTHOME/lib/shell/base16-shell/profile_helper.sh)"
[ -z $BASE16_THEME ] && base16_tomorrow-night

# Load the fuck alias
command -v thefuck >/dev/null 2>&1 && eval "$(thefuck --alias)"

# Load hub alias
command -v hub >/dev/null 2>&1 && eval "$(hub alias -s)"

Expand Down
2 changes: 1 addition & 1 deletion lib/shell/fzf
2 changes: 1 addition & 1 deletion lib/vim/fzf.vim
Submodule fzf.vim updated 1 files
+17 −12 autoload/fzf/vim.vim

0 comments on commit cc1b484

Please sign in to comment.