Added tmux, some changes

This commit is contained in:
Emerson Veenstra 2015-12-02 08:58:40 -05:00
parent 7533513374
commit 589e5dc58a
2 changed files with 56 additions and 44 deletions

47
.tmux.conf Normal file
View File

@ -0,0 +1,47 @@
# vim: set tw=0 nolbr fo-=t
unbind C-b
set -g prefix C-a
bind-key C-a last-window
bind-key C-space set -g status
bind C-p previous-window
bind | split-window -h -c '#{pane_current_path}'
bind - split-window -v -c '#{pane_current_path}'
unbind '"'
unbind %
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
set -g base-index 1
set -g set-titles on
set -g escape-time 0
set -g default-shell "/bin/zsh"
set -g default-terminal "screen-256color"
set -g renumber-windows on
set -g bell-action any
bind r source-file ~/.tmux.conf
set -g set-titles-string "#T"
set -g status-bg black
set -g status-fg default
set-window-option -g window-status-bell-style fg=colour235,bg=colour160
set -g status-left '#(whoami)@#H'
set -g status-left-length 20
set -g status-right '[#S]'
set-window-option -g window-status-current-format "#I:#W#F"
set-window-option -g window-status-format "#I:#W#F"

53
.vimrc
View File

@ -4,8 +4,11 @@ syntax on
" Colors
set background=dark
colorscheme sahara
colorscheme solarized
hi Search cterm=NONE ctermfg=white ctermbg=red
let g:airline_theme='solarized'
let g:airline_powerline_fonts=1
"Disable vi-compatible backspace behavior
set backspace=indent,eol,start
@ -30,11 +33,10 @@ set textwidth=80
" Auto wrap long lines
set formatoptions+=t
set autoindent
set smartindent
set smarttab
" Look and feel
set encoding=utf-8
set noshowmode
set number
set relativenumber
set wildmenu
@ -47,7 +49,8 @@ set incsearch
set hlsearch
set ignorecase
set smartcase
vnoremap <silent> * :call VisualSelection('f')<CR>
vnoremap <silent> # :call VisualSelection('b')<CR>
" Visually display whitespace (this prevents slowness from match command)
set list
set listchars=tab:>>,trail:-,nbsp:+
@ -61,8 +64,7 @@ set hidden
" Remapping things
let mapleader=","
nnoremap <leader><space> :nohlsearch<CR>
set pastetoggle=<leader>p
" Making my life hard on purpose so it is easier later...
nnoremap <buffer><Left> <nop>
nnoremap <buffer><Right> <nop>
@ -100,9 +102,7 @@ inoremap <leader>; <esc>
"Toggle line numbering
nmap <Leader>l :setlocal number!<CR>
"Toggle paste mode
nmap <Leader>p :set paste!<CR>
nmap <Leader>c :nohlsearch<CR>
map <C-J> :bnext<CR>
map <C-K> :bprev<CR>
@ -114,36 +114,10 @@ noremap x "_x
"Paste in visual mode without updating the default register
vnoremap p "_dP
" Backups
set backup
set backupdir=~/.vim-tmp,~/.tmp,~/tmp,/var/tmp,/tmp
set backupskip=/tmp/*,/private/tmp/*
set directory=~/.vim-tmp,~/.tmp,~/tmp,/var/tmp,/tmp
set writebackup
"Enable 256-color mode
set t_Co=256
"Tell vim to remember certain things when we exit
" '10 marks will be remembered for up to 10 previously edited files
" "100 will save up to 100 lines for each register
" :20 up to 20 lines of command-line history will be remembered
" % saves and restores the buffer list
" n... where to save the viminfo files
set viminfo='10,\"100,:20,%,n~/.vim/viminfo
"Function to save the cursor position of the previously opened file
function! ResCur()
if line("'\"") <= line("$")
normal! g`"
return 1
endif
endfunction
augroup resCur
autocmd!
autocmd BufWinEnter * call ResCur()
augroup END
"Jump five lines when scrolling at edge of screen
set scrolljump=1
@ -151,12 +125,6 @@ set scrolljump=1
set scrolloff=5
set sidescrolloff=5
"Enable persistent undo
set undofile "Save undo history when a file is closed
set undodir=$HOME/.vim/undo "Where to save undo histories (must create this dir manually)
set undolevels=1000 "How many undos to save
set undoreload=10000 "Number of lines to save for undo
"Folding
set foldmethod=indent
set nofoldenable
@ -165,7 +133,4 @@ set nofoldenable
"Tell vim to interpret our .vim/after/ftplugin files
filetype plugin on
"Highlight .md files as markdown rather than Modula-2
autocmd BufRead,BufNewFile *.md set filetype=markdown
let loaded_matchparen = 1