From f15d018f72c47e86371ab8c600e507b0be0ffda0 Mon Sep 17 00:00:00 2001 From: Gregory Eremin Date: Tue, 30 Jul 2013 15:58:56 +0700 Subject: [PATCH] Nanana --- bin/git-undo | 5 ---- fish/fish/includes/alias.fish | 5 ++-- git/gitconfig | 12 +++++++++ iterm2/com.googlecode.iterm2.plist | 10 ++++---- vim/vimrc | 40 +++++++++++++++++------------- 5 files changed, 42 insertions(+), 30 deletions(-) delete mode 100755 bin/git-undo diff --git a/bin/git-undo b/bin/git-undo deleted file mode 100755 index 602032d..0000000 --- a/bin/git-undo +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh -# -# Undo your last commit, but don't throw away your changes - -git reset --soft HEAD^ diff --git a/fish/fish/includes/alias.fish b/fish/fish/includes/alias.fish index 655794a..d1b4f2c 100644 --- a/fish/fish/includes/alias.fish +++ b/fish/fish/includes/alias.fish @@ -1,4 +1,3 @@ -alias vi="vim" alias v="vim" alias reload! ". $HOME/.config/fish/config.fish" @@ -16,7 +15,7 @@ alias rspec "bundle exec rspec" alias cap "bundle exec cap" alias cucumber "bundle exec cucumber" -alias mkbundle "bundle install --path vendor/gems" +alias bd "bundle install --path vendor/gems" alias ss "git up; bundle --quiet; bundle exec rake db:migrate" alias rc "rails c" alias rs "rails s" @@ -32,7 +31,7 @@ alias ga "git add -u; git add .; git st" alias gs "git st" alias gd "git diff" alias gp "git push" -alias gu "gut up" +alias gu "git up" alias gb "git br" # OSX diff --git a/git/gitconfig b/git/gitconfig index 75d8d1b..8afa822 100644 --- a/git/gitconfig +++ b/git/gitconfig @@ -12,6 +12,8 @@ ci = commit rd = rebase -i development rh = rebase -i HEAD~5 + unstage = reset + undo = reset --soft HEAD^ [color] diff = auto status = auto @@ -26,9 +28,19 @@ whitespace = nowarn [mergetool] keepBackup = false + prompt = false [difftool] prompt = false [help] autocorrect = 1 [achievement] upload = true +[difftool "Kaleidoscope"] + cmd = ksdiff --partial-changeset --relative-path \"$MERGED\" -- \"$LOCAL\" \"$REMOTE\" +[diff] + tool = Kaleidoscope +[mergetool "Kaleidoscope"] + cmd = ksdiff --merge --output \"$MERGED\" --base \"$BASE\" -- \"$LOCAL\" --snapshot \"$REMOTE\" --snapshot + trustExitCode = true +[merge] + tool = Kaleidoscope diff --git a/iterm2/com.googlecode.iterm2.plist b/iterm2/com.googlecode.iterm2.plist index cf676d0..c69cdde 100644 --- a/iterm2/com.googlecode.iterm2.plist +++ b/iterm2/com.googlecode.iterm2.plist @@ -1690,9 +1690,9 @@ NSWindow Frame NSColorPanel 307 274 214 309 0 0 1440 878 NSWindow Frame Preferences - 304 332 924 485 0 0 1440 878 + 304 314 605 485 0 0 1440 878 NSWindow Frame iTerm Window 0 - 0 380 650 498 0 0 1440 878 + 38 44 1360 796 0 0 1440 878 NSWindow Frame iTerm Window 1 0 452 570 426 0 0 1440 878 NSWindow Frame iTerm Window 2 @@ -2246,11 +2246,11 @@ Name Default Non Ascii Font - Menlo-Regular 14 + Inconsolata 18 Non-ASCII Anti Aliased Normal Font - Menlo-Regular 14 + Inconsolata 18 Option Key Sends 2 Prompt Before Closing 2 @@ -2491,7 +2491,7 @@ SUHasLaunchedBefore SULastCheckTime - 2013-07-05T13:35:54Z + 2013-07-25T13:58:24Z SavePasteHistory Show Toolbelt diff --git a/vim/vimrc b/vim/vimrc index 5bc8f70..65b8a0f 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -26,6 +26,8 @@ Bundle "sjl/badwolf" Bundle "tomasr/molokai" Bundle "nanotech/jellybeans.vim" Bundle "chriskempson/base16-vim" +Bundle "jelera/vim-gummybears-colorscheme" +Bundle "tpope/vim-vividchalk" syntax on filetype plugin on @@ -33,7 +35,7 @@ filetype indent on function! SetRandomColorScheme() let schemes ='peacock grunge freshcut molokai badwolf flatland jellybeans Tomorrow-Night Tomorrow-Night-Eighties ' - let schemes.='base16-eighties ' + let schemes.='base16-eighties vividchalk gummybears' let seconds=str2nr(strftime('%S')) let scheme=split(schemes)[seconds%10] @@ -44,7 +46,7 @@ function! SetRandomColorScheme() endfunction " call SetRandomColorScheme() -colorscheme peacock +colorscheme vividchalk nmap cs :call SetRandomColorScheme() @@ -86,8 +88,8 @@ Bundle 'scrooloose/nerdcommenter' let g:NERDCreateDefaultMappings=0 let g:NERDCompactSexyComs=1 let g:NERDSpaceDelims=1 -nmap / NERDCommenterToggle -vmap / NERDCommenterToggle +nmap cl NERDCommenterToggle +vmap cl NERDCommenterToggle @@ -107,7 +109,7 @@ let g:ctrlp_match_window_reversed=1 Bundle 'vim-ruby/vim-ruby' Bundle 'tpope/vim-markdown' - +Bundle 'vim-scripts/nginx.vim' " Sugar Bundle 'wavded/vim-stylus' @@ -232,6 +234,7 @@ if has("autocmd") autocmd BufNewFile,BufRead *.slim set syntax=slim autocmd BufNewFile,BufRead *.coffee set syntax=coffee autocmd BufNewFile,BufRead *.md set syntax=markdown + autocmd BufNewFile,BufRead *.conf set syntax=nginx endif @@ -241,12 +244,16 @@ endif " ########################## " Set the Leader key to comma instead of backslash -let mapleader = "," +" let mapleader = "," nmap v :e $MYVIMRC -nmap s :w -nmap x :q! +" Buffers +nmap bx :q! +nmap bc :bd +nmap bb :ls:b + +nmap ss :w nmap rr :source $MYVIMRC " Search for the word under cursor @@ -278,28 +285,27 @@ nmap et :tabedit =expand("%:p:h")."/" " Convert Ruby 1.8 hash syntax to 1.9 nmap r18 :%s/:\(\w\+\)\(\s\+\)=>\s\+/\1:\2/ge -" Buffers -nmap b :ls:b - " ####################### " ### Visual Mappings ### " ####################### " Indentation TextMate style -vmap >gv +nmap << +vmap >> " Sudo to write cmap w!! w !sudo tee % >/dev/null " Move 10 lines with Option key -nmap j 10j -nmap k 10k +nmap 10j +nmap 10k " Insert blank lines without entering insert mode -nnoremap j m`o`` -nnoremap k m`O`` +nnoremap m`o`` +nnoremap m`O`` + +nmap m @a function! ToggleLineNumbers() if (&relativenumber == 1)