Add ghc path ( ꒪⌓꒪)
change prompt to ( ꒪⌓꒪)
( ꒪⌓꒪)  .gitconfig修正した

:*:・’゜☆.:*:・’ .:*:・’゜☆’ .:*:・’゜☆’ .:*:・’゜☆’ .:*:
　　　　git pullのデフォルトをrebaseに設定した！！
.:*:・’゜☆’ .:*:・’゜☆’ .:*:・’゜☆’ .:*:・’゜☆’ .:*:・’゜

♪♪┏━━━━━━━━━━━━━━━━━━┓♪♪
┏━━┫ ☆git mergeのデフォルトをno-ffに☆ ┣━━┓
┃　　┗┳━━━━━━━━━━━━━━━━┳┛　　┃
┗━━━┛☆☆★☆ 　 すごい! 　★★★☆★┗━━━┛
Add alias puc ll1
Add Ag.vim
alias gst
setopt transient_rprompt
Apply oh-my-zsh ( ꒪⌓꒪)
Imporve Snippet configurations ( ꒪⌓꒪)
もれいあおｐｇひおあｇへいあおぴひあおｆへいおわｐ
ᑞᔲᗪᘅᕽᒈᔼᔽᓕᖩᔭᔹᒾᓮᑅᖳᗢᘅᖊᓗᐷᘎᘸᔴᕳᔄᕏᑏᘙᒮᕸᓨ᙮ᗔᙇᓎᑍᖤᐸᘄᖇᔭᒭᗈᙾᓥᓐᘸᔸᐠᕪᔭᐲᘊᘷᕍᔊᗨᗤᗩᗀᓏᓯᖠᔜᙩᕈᓚᐸᕔᑔᔪᒃᓇᙰᓪᕨᖷᖃᕽᙈᗈᙎᓨᒣᔫᓓᖌᖶᑋᘎᐪᕾᔁᔒᗳᘃᐹᓲᒴᒆᗥᒦᙳᒽᑳᔽᘧᔦᗱᔀᒂᕢᗼᓵᔖᗻᑽᕥᒵᒼᖃᒥᖋᔬᗶᖰᕋ
m9( ꒪⌓꒪) quickrun.vim周りの設定見直し(colorized rpsec-result),fix syntastic config(automatically open error list)
keymap <C-jklh> to move window in vimshell buffer
( ꒪⌓꒪) Add git-switch command to exec given command with on temporaly switching other branch
zshのrake補完が重すぎて世界が破滅。今は2週目の世界
git-switch: add `--hard` option to execute `git reset --hard HEAD` before run command
changes vimbundle & emacs
[from now] 2013/04/20 10:15:29

diff --git a/.gitconfig b/.gitconfig
index eb57cdf..2cc65d7 100644
--- a/.gitconfig
+++ b/.gitconfig
@@ -17,8 +17,11 @@
   quotepath = false
 [merge]
   tool = vimdiff
+  ff = false
 [branch]
   autosetuprebase = always
+[pull]
+  rebase = true
 [alias]
   s   = status
   st  = status
@@ -32,6 +35,8 @@
   po  = push origin         # push origin
   pof = push -f origin      # force
   pu  = push -u origin      # push origin and set upstream
+  # push current branch to origin with --upstream
+  puc = "!f() { git push origin -u `git symbolic-ref --short HEAD` ;}; f"
   # rebase
   rbm = rebase --merge master       # masterへのrebaseはよく使うのでalias
   rbd = rebase --merge develop
@@ -69,6 +74,7 @@
   la  = log --pretty=\"format:%ad %h (%an): %s\" --date=short  # ざっくりログ出す
   lr  = log origin          # originのlog
   ll = log --date=short --pretty=format:'%Cgreen%h %cd %Cblue%cn%x09%Creset%s' # onelineでlogを出す
+  ll1 = log --date=short --max-count=1 --pretty=format:'%Cgreen%h %cd %Cblue%cn%x09%Creset%s' # onelineでlogを出す
   oneline = log --pretty=oneline
   ranking = shortlog -s -n --no-merges
   # logをtree表示
diff --git a/.vim/snippets/rails.snip b/.vim/snippets/rails.snip
new file mode 100644
index 0000000..2360fb5
--- /dev/null
+++ b/.vim/snippets/rails.snip
@@ -0,0 +1,301 @@
+snippet sc
+abbr    scope :method, lambda
+prev_word   '^'
+    scope :${1}, lambda { ${2} }
+
+snippet dsc
+abbr    default_scope lambda
+prev_word   '^'
+    default_scope lambda { ${1} }
+
+snippet bff
+abbr    before_filter
+prev_word   '^'
+    before_filter :${1:method}
+
+delete      hm
+snippet     hm
+abbr        has_many :objects
+prev_word   '^'
+    has_many :${1:objects}
+
+alias hm has_m
+
+snippet     hmo
+abbr        has_many with options
+prev_word   '^'
+    has_many :${1:objects}${2:, class_name: "${3\}", foreign_key: "${4:reference\}_id"}
+
+snippet     hmt
+abbr        has_many :objects, :through
+prev_word   '^'
+    has_many :${1:objects}, through: ${2:relation}
+
+delete      ho
+snippet     ho
+abbr        has_one :object
+prev_word   '^'
+    has_one :${1:object}
+
+alias ho has_o
+
+delete      bt
+snippet     bt
+abbr        belongs_to :object
+prev_word   '^'
+    belongs_to :${1:object}
+
+alias bt bel
+
+snippet bto
+abbr        belongs_to with options
+prev_word   '^'
+    belongs_to :${1:object}${2:, class_name: "${3\}", foreign_key: "${4:reference\}_id"}
+
+delete      logd
+snippet     logd
+abbr        logger.debug
+    logger.debug(${1})
+
+delete      logi
+snippet     logi
+abbr        logger.info
+    logger.info(${1})
+
+delete      logw
+snippet     logw
+abbr        logger.warn
+    logger.warn(${1})
+
+delete      loge
+snippet     loge
+abbr        logger.error
+    logger.error(${1})
+
+delete      logf
+snippet     logf
+abbr        logger.fatal
+    logger.fatal(${1})
+
+snippet     fla
+abbr        flash[...]
+prev_word   '^'
+    flash[:${1:notice}] = "${2:Successfully created...}"
+
+alias fla flash
+
+snippet rep
+abbr redirect_to (path)
+    redirect_to ${1:model}_path${2:(${3:params\})}
+
+delete      va
+snippet     va
+abbr        validates_associated
+    validates_associated :${1:attr}
+
+delete      vb
+snippet     vb
+abbr        validates_acceptance_of
+    validates_acceptance_of :${1:attr}
+
+delete      vc
+snippet     vc
+abbr        validates_confirmation_of
+    validates_confirmation_of :${1:attr}
+
+delete      ve
+snippet     ve
+abbr        validates_exclusion_of
+    validates_exclusion_of :${1:attr}, in: ${2:%w( ${3:mov avi\} )}
+
+delete      vf
+snippet     vf
+abbr        validates_format_of
+    validates_format_of :${1:attr}, with: /${2:regexp}/
+
+delete      vi
+snippet     vi
+abbr        validates_inclusion_of
+    validates_inclusion_of :${1:attr}, in: ${2:%w( ${3:mov avi\} )}
+
+delete      vl
+snippet     vl
+abbr        validates_length_of
+    validates_length_of :${1:attr}, within: ${2:3..20}
+
+delete      vn
+snippet     vn
+abbr        validates_numericality_of
+    validates_numericality_of :${1:attr}
+
+snippet     vng
+abbr        validates_numericality_of greater_than: n
+    validates_numericality_of :${1:attr}, greater_than: ${2:num}
+
+snippet     vnl
+abbr        validates_numericality_of less_than: n
+    validates_numericality_of :${1:attr}, less_than: ${2:num}
+
+delete      vp
+snippet     vp
+abbr        validates_presence_of
+    validates_presence_of :${1:attr}
+
+delete      vu
+snippet     vu
+abbr        validates_uniqueness_of
+    validates_uniqueness_of :${1:attr}
+
+snippet     aln
+abbr        allow_nil
+    allow_nil: ${1:true}
+
+delete      ra
+snippet     ra
+abbr        render :action
+    render action: ${1}
+
+delete      rc
+snippet     rc
+abbr        render :controller
+    render controller: ${1}
+
+delete      rf
+snippet     rf
+abbr        render :file
+    render file: ${1}
+
+delete      ri
+snippet     ri
+abbr        render :inline
+    render inline: ${1}
+
+delete      rj
+snippet     rj
+abbr        render :json
+    render json: ${1}
+
+delete      rl
+snippet     rl
+abbr        render :layout
+    render layout: ${1}
+
+delete      rp
+snippet     rp
+abbr        render :partial
+    render partial: ${1}
+
+delete      rt
+snippet     rt
+abbr        render :text
+    render text: ${1}
+
+delete      rx
+snippet     rx
+abbr        render :xml
+    render xml: ${1}
+
+delete id
+
+delete object
+
+delete partial
+
+delete      action
+snippet     action
+abbr        action: name
+    action: ${1}
+
+snippet     tzn
+abbr        Time.zone.now
+  Time.zone.now
+
+snippet     res
+abbr        resources
+prev_word   '^'
+    resources :${1:resources}
+
+alias res resources
+
+delete      rst
+snippet     rst
+abbr        respond_to
+prev_word   '^'
+    respond_to do |format|
+        format.html${1: { ${2\} \}}
+        format.json { render json: ${3} }
+    end
+
+snippet     befs
+abbr        before_save
+prev_word   '^'
+    before_save :${1:method}
+
+snippet     befc
+abbr        before_create
+prev_word   '^'
+    before_create :${1:method}
+
+snippet     befu
+abbr        before_update
+prev_word   '^'
+    before_update :${1:method}
+
+snippet     befv
+abbr        before_validation
+prev_word   '^'
+    before_validation :${1:method}
+
+snippet     befvc
+abbr        before_validation_on_create
+prev_word   '^'
+    before_validation_on_create :${1:method}
+
+snippet     befvu
+abbr        before_validation_on_update
+prev_word   '^'
+    before_validation_on_update :${1:method}
+
+snippet     befd
+abbr        before_destroy
+prev_word   '^'
+    before_destroy :${1:method}
+
+snippet     afts
+abbr        after_save
+prev_word   '^'
+    after_save :${1:method}
+
+snippet     aftc
+abbr        after_create
+prev_word   '^'
+    after_create :${1:method}
+
+snippet     aftu
+abbr        after_update
+prev_word   '^'
+    after_update :${1:method}
+
+snippet     aftv
+abbr        after_validation
+prev_word   '^'
+    after_validation :${1:method}
+
+snippet     aftvc
+abbr        after_validation_on_create
+prev_word   '^'
+    after_validation_on_create :${1:method}
+
+snippet     aftvu
+abbr        after_validation_on_update
+prev_word   '^'
+    after_validation_on_update :${1:method}
+
+snippet     aftd
+abbr        after_destroy
+prev_word   '^'
+    after_destroy :${1:method}
+
+snippet     try
+abbr        try(:method)
+    try(:${1:method})
diff --git a/.vim/snippets/rspec.snip b/.vim/snippets/rspec.snip
new file mode 100644
index 0000000..8cf24f7
--- /dev/null
+++ b/.vim/snippets/rspec.snip
@@ -0,0 +1,390 @@
+snippet desc
+abbr    describe end
+prev_word '^'
+    describe "${1:name}" do
+        ${2}
+    end
+
+snippet desch
+abbr    spec_helper describe
+    require 'spec_helper'
+
+    describe ${1:`Snippet_RubySpecNameFromFilename()`} do
+        ${2}
+    end
+
+snippet desccon
+    describe "${1:GET|POST|PUT|DELETE} ${2:/some/path}${3}" do
+        ${4}
+    end
+
+snippet bef
+    before do
+        ${1}
+    end
+
+alias bef before
+
+snippet befa
+    before(:all) do
+        ${1}
+    end
+
+alias befa beforeall
+
+snippet aft
+    after do
+        ${1}
+    end
+
+alias aft after
+
+snippet afta
+    after(:all) do
+        ${1}
+    end
+
+alias afta afterall
+
+snippet con
+    context "${1}" do
+        ${2}
+    end
+
+alias con context
+
+snippet cona
+abbr context after callback
+    context "after #${1:save!}" do
+        before do
+            subject.$1
+        end
+        ${2}
+    end
+
+snippet subjc
+    subject { ${1:FactoryGirl.create(:${2:name\})} }
+
+snippet subjb
+    subject { ${1:FactoryGirl.build(:${2:name\})} }
+
+snippet it
+    it "${1}" do
+        ${2}
+    end
+
+snippet itb
+abbr        it {}
+        it { ${1} }
+
+snippet its
+    it "should ${1:work correctly}" do
+        ${2}
+    end
+
+snippet is
+    it { should ${1} }
+
+snippet isn
+    it { should_not ${1} }
+
+snippet sh
+    should == ${1:value}
+    ${2}
+
+snippet shn
+    should_not == ${1:value}
+    ${2}
+
+snippet shs
+    should satisfy { |${1:obj}| ${2} }
+    ${3}
+
+snippet shp
+    should be_${1:predicate}
+
+alias shp shbe
+
+snippet shh
+    should have(${1:num}).${2:things}
+    ${3}
+
+snippet she
+    should eq(${1:value})
+    ${3}
+
+snippet shne
+    should_not eq(${1:value})
+    ${2}
+
+snippet shnredt
+    response.should_not redirect_to(${1:url})
+    ${2}
+
+snippet shbw
+    should be_within(${1:tolerance}).of(${2:result})
+    ${3}
+
+snippet shnbw
+    should_not be_within(${1:tolerance}).of(${2:result})
+    ${4}
+
+snippet shhal
+    should have_at_least(${1:num}).${2:things}
+    ${3}
+
+snippet shhi
+    should have(${1:n}).records
+    ${2}
+
+snippet shns
+    should_not satisfy { |${1:obj}| ${2} }
+    ${3}
+
+snippet shbko
+    should be_a_kind_of(${1:class})
+    ${2}
+
+snippet shnbko
+    should_not be_a_kind_of(${1:klass})
+    ${2}
+
+snippet shnbe
+    .should_not be_${1:predicate}
+
+snippet shre
+    should raise_error(${1:error})
+    ${2}
+
+snippet shnre
+    should_not raise_error(${1:error})
+    ${2}
+
+alias shre shraise
+
+snippet shc
+    expect {
+        ${1}
+    }.should change(${2:described_class}, :${3:count}).by(${4:1})
+
+alias shc exshc
+
+snippet shnc
+    expect {
+        ${1}
+    }.should_not change(${2:target}, :${3:method})
+
+snippet shrt
+    should respond_to(:${1:sym})
+    ${2}
+
+snippet shnrt
+    should_not respond_to(:${1:sym})
+    ${2}
+
+snippet shr
+    should_receive(:${1:message})${2}
+    ${3}
+
+snippet shnr
+    should_not_receive(:${1:message})${2}
+    ${3}
+
+snippet wia
+    with(${1:args})
+    ${2}
+
+snippet shm
+    should match(/${1:regexp}/)
+    ${2}
+
+snippet shnm
+    should_not match(/${1:regexp}/)
+    ${2}
+
+snippet shredt
+    response.should redirect_to(${1:url})
+    ${2}
+
+snippet shbr
+    response.should be_redirect
+    ${1}
+
+snippet shnbr
+    response.should_not be_redirect
+    ${1}
+
+snippet shbs
+    response.should be_success
+    ${1}
+
+snippet shnbs
+    response.should_not be_success
+    ${1}
+
+snippet shtemp
+    response.should render_template(:${1:template})
+    ${2}
+
+snippet shbio
+    should be_instance_of(${1:class})
+    ${2}
+
+snippet shnbio
+    should_not be_instance_of(${1:klass})
+    ${2}
+
+snippet sc
+abbr shared_context do end
+    shared_context "${1:condition}" do
+        ${2}
+    end
+
+alias sc shared_context
+
+snippet scm
+abbr shared_context with metadata
+    shared_context "${1:condition}", :${2:key} => ${3:value} do
+        ${4}
+    end
+
+snippet inc
+abbr include_context
+    include_context "${1}"
+
+alias inc include_context
+
+snippet se
+abbr shared_examples do end
+    shared_examples "${1:do something}" do
+        ${2}
+    end
+
+alias se shared_examples
+
+snippet sed
+    shared_examples "${1:}" do
+        describe "as $1" do
+            ${2}
+        end
+    end
+
+snippet ibl
+abbr it_behaves_like
+    it_behaves_like '${1}'
+
+alias ibl it_behaves
+
+snippet ine
+abbr include_examples
+    include_examples "${1}"
+
+alias ine include_examples
+
+snippet let
+abbr let {}
+    let(:${1}) { ${2} }
+
+snippet let!
+abbr let! {}
+    let!(:${1}) { ${2} }
+
+snippet letf
+    let(:${1:model}) do
+        FactoryGirl.create(:${2:$1})
+    end
+
+snippet atl
+    at_least(${1:n}).times
+
+snippet atm
+    at_most(${1:n}).times
+
+snippet on
+    once
+
+snippet tw
+    twice
+
+snippet ber
+    be_redirect
+
+snippet ex
+    exactly(${1:n}).times
+
+alias ex exact
+
+snippet annot
+    any_number_of_times
+
+snippet shham
+    ${1:target}.should have_at_most(${2:num}).${3:things}
+    ${4}
+
+snippet ant
+    and_throw(${1:sym})
+
+snippet any
+    and_yield(${1:values})
+
+snippet mat
+    RSpec::Matchers.define :${1:matcher_name} do
+        match do |model|
+            # return Boolean
+            ${2}
+        end
+    end
+
+alias mat matcher
+
+
+snippet anr
+    and_return(${1:value})
+
+snippet anrb
+    and_return { ${1} }
+
+snippet anra
+    and_raise(${1:exception})
+
+snippet st
+    stub(:${1:method}).and_returns(${2:return})
+
+alias st stub
+
+snippet sm
+    stub_model(${1:model}, {${2}})
+snippet mm
+    mock_model(${1:model})${2}
+
+snippet moc
+    ${1:var} = mock("${2:mock_name}"${3:, :null_object => true})
+    ${4}
+
+snippet facb
+    FactoryGirl.build(:${1})
+
+snippet fac
+    FactoryGirl(:${1}, ${2})
+
+snippet facc
+    FactoryGirl.create(:${1})
+
+snippet facs
+    sequence(:${1}) {|n| "${2}#{n}"}
+
+snippet facn
+    FactoryGirl.next(:${1:sequence-name})
+
+snippet faca
+    f.${1:model} {|a| a.association(:${2:$1})}
+
+snippet facd
+    FactoryGirl.define do
+        ${1}
+    end
+
+snippet facf
+    factory ${1:name} do
+        ${2}
+    end
diff --git a/.vim/syntax/rspec-result.vim b/.vim/syntax/rspec-result.vim
new file mode 100644
index 0000000..de470eb
--- /dev/null
+++ b/.vim/syntax/rspec-result.vim
@@ -0,0 +1,55 @@
+" .vim/syntax/rspec-result.vim
+" quickrun.vimでRSpecの実行結果のカラー設定をする | teranishihiroki.com :
+" http://teranishihiroki.com/quickrun-vim%E3%81%A7rspec%E3%81%AE%E5%AE%9F%E8%A1%8C%E7%B5%90%E6%9E%9C%E3%81%AE%E3%82%AB%E3%83%A9%E3%83%BC%E8%A8%AD%E5%AE%9A%E3%82%92%E3%81%99%E3%82%8B/
+"
+
+if exists("b:current_syntax")
+  finish
+endif
+
+if !exists("main_syntax")
+  let main_syntax = 'rspec-result'
+endif
+
+"大文字と小文字を区別する
+syntax case match
+
+syntax match RSpecGreen /^[\.F]*\.[\.F]*$/
+syntax match RSpecGreen /^.*, 0 failures$/
+syntax match RSpecRed /F/
+syntax match RSpecRed /^.*, [1-9]* failures.*$/
+syntax match RSpecRed /^.*, 1 failure.*$/
+syntax match RSpecRed /^ *(.*$/
+syntax match RSpecRed /^ *expected.*$/
+syntax match RSpecRed /^ *got.*$/
+syntax match RSpecRed /^ *Failure\/Error:.*$/
+syntax match RSpecRed /^.*(FAILED - [0-9]*)$/
+syntax match RSpecRed /^rspec .*:.*$/
+syntax match RSpecComment / # .*$/
+syntax match RSpecNormal /^Failures:/
+syntax match RSpecNormal /^Finished/
+syntax match RSpecNormal /^Failed/
+
+" 背景色ver.
+" highlight RSpecGreen   ctermfg=White ctermbg=Green guifg=White guibg=Green
+" highlight RSpecRed     ctermfg=White ctermbg=Red   guifg=White guibg=Red
+" highlight RSpecComment ctermfg=White ctermbg=Cyan  guifg=White guibg=Cyan
+" highlight RSpecNormal  ctermfg=Black ctermbg=White guifg=Black guibg=White
+
+" 文字色ver.(※ただしMacVimKaoriYaだとうまく動かなかった)
+" highlight RSpecGreen   ctermfg=Green ctermbg=none guifg=Green guibg=none
+" highlight RSpecRed     ctermfg=Red   ctermbg=none guifg=Red   guibg=none
+" highlight RSpecComment ctermfg=Cyan  ctermbg=none guifg=Cyan  guibg=none
+" highlight RSpecNormal  ctermfg=White ctermbg=none guifg=Black guibg=White
+
+" 文字色ver.(noneのとこ消したらうまくいった)
+highlight RSpecGreen   ctermfg=Green guifg=Green
+highlight RSpecRed     ctermfg=Red   guifg=Red
+highlight RSpecComment ctermfg=Cyan  guifg=Cyan
+highlight RSpecNormal  ctermfg=White guifg=Black guibg=White
+
+let b:current_syntax = 'rspec-result'
+
+if main_syntax == 'rspec-result'
+  unlet main_syntax
+endif
diff --git a/.vimrc.bundle b/.vimrc.bundle
index da7022e..5103eff 100644
--- a/.vimrc.bundle
+++ b/.vimrc.bundle
@@ -107,6 +107,8 @@ endif

   " Gauche の自動補完
   NeoBundle 'aharisu/Gauche-Complete'
+  " various langueages snippets
+  NeoBundle 'honza/snipmate-snippets'

   " for rsense
   NeoBundle 'm2ym/rsense'
@@ -121,7 +123,8 @@ endif

 " Searching/Moving{{{
   " smooth_scroll.vim : スクロールを賢く
-  NeoBundle 'Smooth-Scroll'
+  " NeoBundle 'Smooth-Scroll'
+  NeoBundle 'yuroyoro/smooth_scroll.vim'

   " vim-smartword : 単語移動がスマートな感じで
   NeoBundle 'smartword'
@@ -147,6 +150,9 @@ endif
   " open-browser.vim : カーソルの下のURLを開くor単語を検索エンジンで検索
   NeoBundle 'tyru/open-browser.vim'

+  " VimからThe Silver Searcherを利用する
+  "  http://blog.glidenote.com/blog/2013/02/28/the-silver-searcher-better-than-ack/
+  NeoBundle 'rking/ag.vim'
 " }}}

 " Programming {{{
@@ -244,7 +250,10 @@ endif
   " vimproc : vimから非同期実行。vimshelleで必要
   NeoBundle 'Shougo/vimproc', {
       \ 'build' : {
+      \     'windows' : 'make -f make_mingw32.mak',
+      \     'cygwin' : 'make -f make_cygwin.mak',
       \     'mac' : 'make -f make_mac.mak',
+      \     'unix' : 'make -f make_unix.mak',
       \    },
       \ }

@@ -273,7 +282,7 @@ endif
   NeoBundle 'yuroyoro/vimdoc_ja'

   " vim上のtwitter client
-  NeoBundle 'TwitVim'
+  " NeoBundle 'TwitVim'

   " Lingrのclient
   NeoBundle 'tsukkee/lingr-vim'
@@ -292,6 +301,9 @@ endif
   " A framework to read/write fake:path
   NeoBundle 'kana/vim-metarw'

+  " shows a git diff in the 'gutter' (sign column)
+  NeoBundle 'airblade/vim-gitgutter'
+
 " }}}

 " ColorSchema{{{{
diff --git a/.vimrc.completion.neocomplcache b/.vimrc.completion.neocomplcache
index affba22..b62286d 100644
--- a/.vimrc.completion.neocomplcache
+++ b/.vimrc.completion.neocomplcache
@@ -50,8 +50,20 @@ let g:neocomplcache_keyword_patterns['default'] = '\h\w*'
 let g:neocomplcache_snippets_dir = $HOME.'/.vim/snippets'

 " スニペット
-imap <C-y> <Plug>(neocomplcache_snippets_expand)
-smap <C-k> <Plug>(neocomplcache_snippets_expand)
+imap <C-y> <Plug>(neosnippet_expand_or_jump)
+smap <C-k> <Plug>(neosnippet_expand_or_jump)
+
+" SuperTab like snippets behavior.
+imap <expr><TAB> neosnippet#jumpable() ? "\<Plug>(neosnippet_expand_or_jump)" : pumvisible() ? "\<C-n>" : "\<TAB>"
+smap <expr><TAB> neosnippet#jumpable() ? "\<Plug>(neosnippet_expand_or_jump)" : "\<TAB>"
+
+" For snippet_complete marker.
+if has('conceal')
+  set conceallevel=2 concealcursor=i
+endif
+
+" snipet template dirs
+let g:neosnippet#snippets_directory = '~/.vim/snipmate-snippets/snippets  ~/dotfiles/.vim/snippets'

 " 補完を選択しpopupを閉じる
 " inoremap <expr><C-y> neocomplcache#close_popup()
@@ -63,8 +75,6 @@ inoremap <expr><TAB> pumvisible() ? "\<C-n>" : "\<TAB>"
 inoremap <expr><C-g>     neocomplcache#undo_completion()
 " 補完候補の共通部分までを補完する
 inoremap <expr><C-s> neocomplcache#complete_common_string()
-" SuperTab like snippets behavior.
-imap <expr><TAB> neocomplcache#sources#snippets_complete#expandable() ? "\<Plug>(neocomplcache_snippets_expand)" : pumvisible() ? "\<C-n>" : "\<TAB>"
 " C-kを押すと行末まで削除
 " inoremap <C-k> <C-o>D
 " C-nでneocomplcache補完
diff --git a/.vimrc.editing b/.vimrc.editing
index 8353852..60eb4bc 100644
--- a/.vimrc.editing
+++ b/.vimrc.editing
@@ -34,10 +34,24 @@ command! Pt :set paste!
 " インサートモード中に<C-o>でyankした内容をputする
 inoremap <C-o> <ESC>:<C-U>YRPaste 'p'<CR>i

-" y9で行末までヤンク
+" y9 ydで行末までヤンク
 nmap y9 y$
-" y0で行頭までヤンク
+nmap yd y$
+" y0 ykで行頭までヤンク
 nmap y0 y^
+nmap yk y^
+
+" カーソルから行頭まで削除
+nnoremap <silent> <C-d> d0
+
+" カーソルから行頭まで削除(インサートモード)
+inoremap <silent> <C-k> <Esc>lc^
+" カーソルから行末まで削除(インサートモード)
+inoremap <silent> <C-d> <Esc>lc$
+" カーソルから行頭までヤンク(インサートモード)
+inoremap <silent> <C-y>e <Esc>ly0<Insert>
+" カーソルから行末までヤンク(インサートモード)
+inoremap <silent> <C-y>0 <Esc>ly$<Insert>

 "
 " 括弧を自動補完
diff --git a/.vimrc.plugins_setting b/.vimrc.plugins_setting
index dcc66f8..c8322c8 100644
--- a/.vimrc.plugins_setting
+++ b/.vimrc.plugins_setting
@@ -162,6 +162,13 @@ else
     hi IndentGuidesEven ctermbg=lightgrey
 endif

+
+"------------------------------------
+" smooth_scroll.vim
+"------------------------------------
+map  :call SmoothScroll("d",1, 1)<CR>
+map  :call SmoothScroll("u",1, 1)<CR>
+
 "------------------------------------
 " gundo.Vim
 "------------------------------------
@@ -297,6 +304,17 @@ function! g:my_preexec(cmdline, context)
   return a:cmdline
 endfunction

+function! VimShellCustomKeyMapping()
+  nnoremap <buffer> <C-j> <C-w>j
+  nnoremap <buffer> <C-k> <C-w>k
+  nnoremap <buffer> <C-l> <C-w>l
+  nnoremap <buffer> <C-h> <C-w>h
+  inoremap <buffer> <C-j> <C-w>j
+  inoremap <buffer> <C-k> <C-w>k
+  inoremap <buffer> <C-l> <C-w>l
+  inoremap <buffer> <C-h> <C-w>h
+endfunction
+
 autocmd FileType vimshell
 \ call vimshell#altercmd#define('g', 'git')
 \| call vimshell#altercmd#define('i', 'iexe')
@@ -307,7 +325,12 @@ autocmd FileType vimshell
 \| call vimshell#hook#set('preprompt', ['g:my_preprompt'])
 \| call vimshell#hook#set('preexec', ['g:my_preexec'])

+autocmd FileType vimshell call VimShellCustomKeyMapping()
+autocmd FileType int-rails call VimShellCustomKeyMapping()
 command! Vs :VimShell
+command! Vsrc :VimShellInteractive rails console
+nmap <Leader>pry :VimShellInteractive pry<CR>
+nmap <Leader>irb :VimShellInteractive irb<CR>

 "------------------------------------
@@ -331,6 +354,8 @@ nnoremap <silent> [unite]u  :<C-u>Unite -no-split buffer file_mru<CR>
 nnoremap <silent> [unite]m  :<C-u>Unite -no-split file_mru<CR>
 " 現在のバッファのカレントディレクトリからファイル一覧
 nnoremap <silent> [unite]d  :<C-u>UniteWithBufferDir -no-split file<CR>
+" snippet一覧
+nnoremap <silent> [unite]s  :<C-u>Unite snippet<CR>

 " nnoremap <silent> [unite]b  :<C-u>UniteWithBufferDir -buffer-name=files buffer file_mru bookmark file<CR>

@@ -376,12 +401,19 @@ cnoremap UO Unite outline<Enter>
 " quickrun.vim
 "------------------------------------
 let g:quickrun_config = {}
-let g:quickrun_config._ = {'runner' : 'vimproc'}
+let g:quickrun_config._ = {
+  \ 'runner' : 'vimproc',
+  \ "runner/vimproc/updatetime" : 60,
+  \ 'outputter/buffer/split' : ':botright 8sp',
+  \ 'outputter/buffer/close_on_empty' : 1
+  \}
+
 let g:quickrun_config['rspec/bundle'] = {
   \ 'type': 'rspec/bundle',
   \ 'command': "rspec",
   \ 'cmdopt': "-l %{line('.')}",
   \ 'exec': "bundle exec %c %o %s ",
+  \ 'outputter/buffer/filetype': 'rspec-result',
   \ 'filetype': 'rspec-result'
   \}
 let g:quickrun_config['rspec/normal'] = {
@@ -389,11 +421,17 @@ let g:quickrun_config['rspec/normal'] = {
   \ 'command': "rspec",
   \ 'cmdopt': "-l %{line('.')}",
   \ 'exec': '%c %o %s',
+  \ 'outputter/buffer/filetype': 'rspec-result',
   \ 'filetype': 'rspec-result'
   \}
 function! RSpecQuickrun()
   let b:quickrun_config = {'type' : 'rspec/bundle'}
 endfunction
+
+" <C-c> で実行を強制終了させる
+" quickrun.vim が実行していない場合には <C-c> を呼び出す
+nnoremap <expr><silent> <C-c> quickrun#is_running() ?  quickrun#sweep_sessions() : "\<C-c>"
+
 autocmd BufReadPost *_spec.rb call RSpecQuickrun()

 "------------------------------------
@@ -408,6 +446,8 @@ let g:pydiction_location = '~/.vim/bundle/pydiction/complete-dict'
 let g:syntastic_enable_signs = 1
 " 可能ならhighligt表示する
 let g:syntastic_enable_highlighting = 1
+" 自動的に開いたり閉じたりする
+let g:syntastic_auto_loc_list=1

 "------------------------------------
 " toggle.vim
diff --git a/.zshrc b/.zshrc
index 7b82054..784332e 100644
--- a/.zshrc
+++ b/.zshrc
@@ -1,683 +1,40 @@
-# users generic .zshrc file for zsh(1)
+# Path to your oh-my-zsh configuration.
+ZSH=$HOME/.oh-my-zsh

+# Set name of the theme to load.
+# Look in ~/.oh-my-zsh/themes/
+# Optionally, if you set this to "random", it'll load a random theme each
+# time that oh-my-zsh is loaded.
+# ZSH_THEME="robbyrussell"

-## Environment variable configuration
-#
-# LANG
-# http://curiousabt.blog27.fc2.com/blog-entry-65.html
-export LANG=ja_JP.UTF-8
-export LESSCHARSET=utf-8
+# Example aliases
+# alias zshconfig="mate ~/.zshrc"
+# alias ohmyzsh="mate ~/.oh-my-zsh"

+# Set to this to use case-sensitive completion
+# CASE_SENSITIVE="true"

-## Backspace key
-#
-bindkey "^?" backward-delete-char
+# Comment this out to disable bi-weekly auto-update checks
+# DISABLE_AUTO_UPDATE="true"

-# プロンプトが表示されるたびにプロンプト文字列を評価、置換する
-setopt prompt_subst
+# Uncomment to change how many often would you like to wait before auto-updates occur? (in days)
+# export UPDATE_ZSH_DAYS=13

-## Default shell configuration
-# colors enables us to idenfity color by $fg[red].
-autoload colors
-colors
-case ${UID} in
-0)
-    PROMPT="%B%{${fg[red]}%}%/#%{${reset_color}%}%b "
-    PROMPT2="%B%{${fg[red]}%}%_#%{${reset_color}%}%b "
-    SPROMPT="%B%{${fg[red]}%}%r is correct? [n,y,a,e]:%{${reset_color}%}%b "
-    [ -n "${REMOTEHOST}${SSH_CONNECTION}" ] &&
-        PROMPT="%{${fg[cyan]}%}$(echo ${HOST%%.*} | tr '[a-z]' '[A-Z]') ${PROMPT}"
-    ;;
-*)
-    #
-    # Color
-    #
-    DEFAULT=$'%{\e[1;0m%}'
-    RESET="%{${reset_color}%}"
-    GREEN="%{${fg[green]}%}"
-    BLUE="%{${fg[blue]}%}"
-    RED="%{${fg[red]}%}"
-    CYAN="%{${fg[cyan]}%}"
-    WHITE="%{${fg[white]}%}"
+# Uncomment following line if you want to disable colors in ls
+# DISABLE_LS_COLORS="true"

-    #
-    # Prompt
-    #
-    PROMPT='%{$fg_bold[blue]%}${USER}@%m ${RESET}${WHITE}$ ${RESET}'
-    RPROMPT='${RESET}${WHITE}[${BLUE}%(5~,%-2~/.../%2~,%~)% ${WHITE}]${RESET}'
+# Uncomment following line if you want to disable autosetting terminal title.
+DISABLE_AUTO_TITLE="true"

-    #
-    # Vi入力モードでPROMPTの色を変える
-    # http://memo.officebrook.net/20090226.html
-    function zle-line-init zle-keymap-select {
-      case $KEYMAP in
-        vicmd)
-        PROMPT="%{$fg_bold[cyan]%}${USER}@%m ${RESET}${WHITE}$ ${RESET}"
-        ;;
-        main|viins)
-        PROMPT="%{$fg_bold[blue]%}${USER}@%m ${RESET}${WHITE}$ ${RESET}"
-        ;;
-      esac
-      zle reset-prompt
-    }
-    zle -N zle-line-init
-    zle -N zle-keymap-select
+# Uncomment following line if you want red dots to be displayed while waiting for completion
+# COMPLETION_WAITING_DOTS="true"

-    # Show git branch when you are in git repository
-    # http://d.hatena.ne.jp/mollifier/20100906/p1
+# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
+# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
+# Example format: plugins=(rails git textmate ruby lighthouse)

-    autoload -Uz add-zsh-hook
-    autoload -Uz vcs_info
+plugins=(brew bundler capistrano coffee command-not-found extract gem git git-flow github heroku history history-substring-search lein mvn node npm osx pip python rails rails3 rbenv redis-cli rsync ruby rvm svn thor urltools vagrant vi-mode vundle yum)
+source $ZSH/oh-my-zsh.sh

-    zstyle ':vcs_info:*' enable git svn hg bzr
-    zstyle ':vcs_info:*' formats '(%s)-[%b]'
-    zstyle ':vcs_info:*' actionformats '(%s)-[%b|%a]'
-    zstyle ':vcs_info:(svn|bzr):*' branchformat '%b:r%r'
-    zstyle ':vcs_info:bzr:*' use-simple true
-
-    autoload -Uz is-at-least
-    if is-at-least 4.3.10; then
-      # この check-for-changes が今回の設定するところ
-      zstyle ':vcs_info:git:*' check-for-changes true
-      zstyle ':vcs_info:git:*' stagedstr "+"    # 適当な文字列に変更する
-      zstyle ':vcs_info:git:*' unstagedstr "-"  # 適当の文字列に変更する
-      zstyle ':vcs_info:git:*' formats '(%s)-[%c%u%b]'
-      zstyle ':vcs_info:git:*' actionformats '(%s)-[%c%u%b|%a]'
-    fi
-
-    function _update_vcs_info_msg() {
-        psvar=()
-        LANG=en_US.UTF-8 vcs_info
-        psvar[2]=$(_git_not_pushed)
-        [[ -n "$vcs_info_msg_0_" ]] && psvar[1]="$vcs_info_msg_0_"
-    }
-    add-zsh-hook precmd _update_vcs_info_msg
-
-    # show status of git pushed to HEAD in prompt
-    function _git_not_pushed()
-    {
-      if [ "$(git rev-parse --is-inside-work-tree 2>/dev/null)" = "true" ]; then
-        head="$(git rev-parse HEAD)"
-        for x in $(git rev-parse --remotes)
-        do
-          if [ "$head" = "$x" ]; then
-            return 0
-          fi
-        done
-        echo "|?"
-      fi
-      return 0
-    }
-
-    # git のブランチ名 *と作業状態* を zsh の右プロンプトに表示＋ status に応じて色もつけてみた - Yarukidenized:ヤルキデナイズド :
-    # http://d.hatena.ne.jp/uasi/20091025/1256458798
-    autoload -Uz VCS_INFO_get_data_git; VCS_INFO_get_data_git 2> /dev/null
-
-    function rprompt-git-current-branch {
-      local name st color gitdir action pushed
-      if [[ "$PWD" =~ '/\.git(/.*)?$' ]]; then
-              return
-      fi
-
-      name=`git rev-parse --abbrev-ref=loose HEAD 2> /dev/null`
-      if [[ -z $name ]]; then
-              return
-      fi
-
-      gitdir=`git rev-parse --git-dir 2> /dev/null`
-      action=`VCS_INFO_git_getaction "$gitdir"` && action="|$action"
-      pushed="`_git_not_pushed`"
-
-      st=`git status 2> /dev/null`
-      if [[ "$st" =~ "(?m)^nothing to" ]]; then
-        color=%F{green}
-      elif [[ "$st" =~ "(?m)^nothing added" ]]; then
-        color=%F{yellow}
-      elif [[ "$st" =~ "(?m)^# Untracked" ]]; then
-        color=%B%F{red}
-      else
-        color=%F{red}
-      fi
-
-      echo "[$color$name$action$pushed%f%b]"
-    }
-
-    # PCRE 互換の正規表現を使う
-    setopt re_match_pcre
-
-    RPROMPT='`rprompt-git-current-branch`${RESET}${WHITE}[${BLUE}%(5~,%-2~/.../%2~,%~)${WHITE}]${RESET}'
-
-    ;;
-esac
-
-# 指定したコマンド名がなく、ディレクトリ名と一致した場合 cd する
-setopt auto_cd
-
-# cd でTabを押すとdir list を表示
-setopt auto_pushd
-
-# ディレクトリスタックに同じディレクトリを追加しないようになる
-setopt pushd_ignore_dups
-
-# コマンドのスペルチェックをする
-setopt correct
-
-# コマンドライン全てのスペルチェックをする
-setopt correct_all
-
-# 上書きリダイレクトの禁止
-setopt no_clobber
-
-# 補完候補リストを詰めて表示
-setopt list_packed
-
-# auto_list の補完候補一覧で、ls -F のようにファイルの種別をマーク表示
-setopt list_types
-
-# 補完候補が複数ある時に、一覧表示する
-setopt auto_list
-
-# コマンドラインの引数で --prefix=/usr などの = 以降でも補完できる
-setopt magic_equal_subst
-
-# カッコの対応などを自動的に補完する
-setopt auto_param_keys
-
-# ディレクトリ名の補完で末尾の / を自動的に付加し、次の補完に備える
-setopt auto_param_slash
-
-# {a-c} を a b c に展開する機能を使えるようにする
-setopt brace_ccl
-
-# シンボリックリンクは実体を追うようになる
-#setopt chase_links
-
-# 補完キー（Tab,  Ctrl+I) を連打するだけで順に補完候補を自動で補完する
-setopt auto_menu
-
-# sudoも補完の対象
-zstyle ':completion:*:sudo:*' command-path /usr/local/sbin /usr/local/bin /usr/sbin /usr/bin /sbin /bin
-
-# 色付きで補完する
-zstyle ':completion:*' list-colors di=34 fi=0
-#zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
-
-# 複数のリダイレクトやパイプなど、必要に応じて tee や cat の機能が使われる
-setopt multios
-
-# 最後がディレクトリ名で終わっている場合末尾の / を自動的に取り除かない
-setopt noautoremoveslash
-
-# beepを鳴らさないようにする
-setopt nolistbeep
-
-# Match without pattern
-# ex. > rm *~398
-# remove * without a file "398". For test, use "echo *~398"
-setopt extended_glob
-
-## Keybind configuration
-#
-# emacs like keybind (e.x. Ctrl-a goes to head of a line and Ctrl-e goes
-#   to end of it)
-#
-bindkey -v
-
-# historical backward/forward search with linehead string binded to ^P/^N
-#
-autoload history-search-end
-zle -N history-beginning-search-backward-end history-search-end
-zle -N history-beginning-search-forward-end history-search-end
-bindkey "^p" history-beginning-search-backward-end
-bindkey "^n" history-beginning-search-forward-end
-bindkey "\\ep" history-beginning-search-backward-end
-bindkey "\\en" history-beginning-search-forward-end
-
-# glob(*)によるインクリメンタルサーチ
-bindkey '^R' history-incremental-pattern-search-backward
-bindkey '^S' history-incremental-pattern-search-forward
-
-## Command history configuration
-HISTFILE=~/.zsh_history
-HISTSIZE=10000
-SAVEHIST=10000
-
-# 登録済コマンド行は古い方を削除
-setopt hist_ignore_all_dups
-
-# historyの共有
-setopt share_history
-
-# 余分な空白は詰める
-setopt hist_reduce_blanks
-
-# add history when command executed.
-setopt inc_append_history
-
-# history (fc -l) コマンドをヒストリリストから取り除く。
-setopt hist_no_store
-# サスペンド中のプロセスと同じコマンド名を実行した場合はリジュームする
-#setopt auto_resume
-
-# =command を command のパス名に展開する
-#setopt equals
-
-# ファイル名で #, ~, ^ の 3 文字を正規表現として扱う
-#setopt extended_glob
-
-# zsh の開始・終了時刻をヒストリファイルに書き込む
-#setopt extended_history
-
-# Ctrl+S/Ctrl+Q によるフロー制御を使わないようにする
-#setopt NO_flow_control
-
-# 各コマンドが実行されるときにパスをハッシュに入れる
-#setopt hash_cmds
-
-# コマンドラインの先頭がスペースで始まる場合ヒストリに追加しない
-#setopt hist_ignore_space
-
-# ヒストリを呼び出してから実行する間に一旦編集できる状態になる
-#setopt hist_verify
-
-# シェルが終了しても裏ジョブに HUP シグナルを送らないようにする
-#setopt NO_hup
-
-# Ctrl+D では終了しないようになる（exit, logout などを使う）
-#setopt ignore_eof
-
-# コマンドラインでも # 以降をコメントと見なす
-#setopt interactive_comments
-
-# メールスプール $MAIL が読まれていたらワーニングを表示する
-#setopt mail_warning
-
-# ファイル名の展開でディレクトリにマッチした場合末尾に / を付加する
-#setopt mark_dirs
-
-# ファイル名の展開で、辞書順ではなく数値的にソートされるようになる
-#setopt numeric_glob_sort
-
-# コマンド名に / が含まれているとき PATH 中のサブディレクトリを探す
-setopt path_dirs
-
-# 戻り値が 0 以外の場合終了コードを表示する
-# setopt print_exit_value
-
-# pushd を引数なしで実行した場合 pushd $HOME と見なされる
-#setopt pushd_to_home
-
-# rm * などの際、本当に全てのファイルを消して良いかの確認しないようになる
-#setopt rm_star_silent
-
-# rm_star_silent の逆で、10 秒間反応しなくなり、頭を冷ます時間が与えられる
-#setopt rm_star_wait
-
-# for, repeat, select, if, function などで簡略文法が使えるようになる
-#setopt short_loops
-
-# デフォルトの複数行コマンドライン編集ではなく、１行編集モードになる
-#setopt single_line_zle
-
-# コマンドラインがどのように展開され実行されたかを表示するようになる
-#setopt xtrace
-
-# ^でcd ..する
-function cdup() {
-echo
-cd ..
-zle reset-prompt
-}
-zle -N cdup
-# bindkey '\^' cdup
-
-# ctrl-w, ctrl-bキーで単語移動
-bindkey "^W" forward-word
-bindkey "^B" backward-word
-
-# back-wordでの単語境界の設定
-autoload -Uz select-word-style
-select-word-style default
-zstyle ':zle:*' word-chars " _-./;@"
-zstyle ':zle:*' word-style unspecified
-
-# URLをコピペしたときに自動でエスケープ
-autoload -Uz url-quote-magic
-zle -N self-insert url-quote-magic
-
-# 勝手にpushd
-setopt autopushd
-
-# エラーメッセージ本文出力に色付け
-e_normal=`echo -e "¥033[0;30m"`
-e_RED=`echo -e "¥033[1;31m"`
-e_BLUE=`echo -e "¥033[1;36m"`
-
-function make() {
-    LANG=C command make "$@" 2>&1 | sed -e "s@[Ee]rror:.*@$e_RED&$e_normal@g" -e "s@cannot¥sfind.*@$e_RED&$e_normal@g" -e "s@[Ww]arning:.*@$e_BLUE&$e_normal@g"
-}
-function cwaf() {
-    LANG=C command ./waf "$@" 2>&1 | sed -e "s@[Ee]rror:.*@$e_RED&$e_normal@g" -e "s@cannot¥sfind.*@$e_RED&$e_normal@g" -e "s@[Ww]arning:.*@$e_BLUE&$e_normal@g"
-}
-
-## Completion configuration
-#
-fpath=(~/.zsh/functions/Completion ${fpath})
-autoload -U compinit
-compinit -u
-
-
-## zsh editor
-#
-autoload zed
-
-
-## Prediction configuration
-#
-autoload predict-on
-#predict-off
-
-## Command Line Stack [Esc]-[q]
-bindkey -a 'q' push-line
-
-
-## Alias configuration
-#
-# expand aliases before completing
-#
-setopt complete_aliases     # aliased ls needs if file/dir completions work
-
-alias where="command -v"
-
-case "${OSTYPE}" in
-freebsd*|darwin*)
-    alias ls="ls -alG"
-    zle -N expand-to-home-or-insert
-    bindkey "@"  expand-to-home-or-insert
-    ;;
-linux*)
-    alias la="ls -al"
-    ;;
-esac
-
-
-case "${OSTYPE}" in
-# MacOSX
-darwin*)
-    export PATH=$PATH:/opt/local/bin:/opt/local/sbin/
-    export PATH=$PATH:/System/Library/PrivateFrameworks/Apple80211.framework/Versions/A/Resources/
-    ;;
-freebsd*)
-    case ${UID} in
-    0)
-        updateports()
-        {
-            if [ -f /usr/ports/.portsnap.INDEX ]
-            then
-                portsnap fetch update
-            else
-                portsnap fetch extract update
-            fi
-            (cd /usr/ports/; make index)
-
-            portversion -v -l \<
-        }
-        alias appsupgrade='pkgdb -F && BATCH=YES NO_CHECKSUM=YES portupgrade -a'
-        ;;
-    esac
-    ;;
-esac
-
-
-## terminal configuration
-# http://journal.mycom.co.jp/column/zsh/009/index.html
-unset LSCOLORS
-
-case "${TERM}" in
-xterm)
-    export TERM=xterm-color
-
-    ;;
-kterm)
-    export TERM=kterm-color
-    # set BackSpace control character
-
-    stty erase
-    ;;
-
-cons25)
-    unset LANG
-  export LSCOLORS=ExFxCxdxBxegedabagacad
-
-    export LS_COLORS='di=01;32:ln=01;35:so=01;32:ex=01;31:bd=46;34:cd=43;34:su=41;30:sg=46;30'
-    zstyle ':completion:*' list-colors \
-        'di=;36;1' 'ln=;35;1' 'so=;32;1' 'ex=31;1' 'bd=46;34' 'cd=43;34'
-    ;;
-
-kterm*|xterm*)
-   # Terminal.app
-#    precmd() {
-#        echo -ne "\033]0;${USER}@${HOST%%.*}:${PWD}\007"
-#    }
-    # export LSCOLORS=exfxcxdxbxegedabagacad
-    # export LSCOLORS=gxfxcxdxbxegedabagacad
-    # export LS_COLORS='di=1;34:ln=35:so=32:pi=33:ex=31:bd=46;34:cd=43;34:su=41;30:sg=46;30'
-
-    export CLICOLOR=1
-    export LSCOLORS=ExFxCxDxBxegedabagacad
-
-    zstyle ':completion:*' list-colors \
-        'di=36' 'ln=35' 'so=32' 'ex=31' 'bd=46;34' 'cd=43;34'
-    ;;
-
-dumb)
-    echo "Welcome Emacs Shell"
-    ;;
-esac
-
-
-
-export EDITOR=vim
-export PATH=$PATH:$HOME/local/bin:/usr/local/git/bin
-export PATH=$PATH:$HOME/dotfiles/bin
-export PATH=$PATH:/sbin:/usr/local/bin
-export MANPATH=$MANPATH:/opt/local/man:/usr/local/share/man
-
-expand-to-home-or-insert () {
-        if [ "$LBUFFER" = "" -o "$LBUFFER[-1]" = " " ]; then
-                LBUFFER+="~/"
-        else
-                zle self-insert
-        fi
-}
-
-# C-M-h でチートシートを表示する
-cheat-sheet () { zle -M "`cat ~/dotfiles/.zsh/cheat-sheet`" }
-zle -N cheat-sheet
-# bindkey "^[^h" cheat-sheet
-
-# zsh の exntended_glob と HEAD^^^ を共存させる。
-# http://subtech.g.hatena.ne.jp/cho45/20080617/1213629154
-typeset -A abbreviations
-abbreviations=(
-  "L"    "| $PAGER"
-  "G"    "| grep"
-
-  "HEAD^"     "HEAD\\^"
-  "HEAD^^"    "HEAD\\^\\^"
-  "HEAD^^^"   "HEAD\\^\\^\\^"
-  "HEAD^^^^"  "HEAD\\^\\^\\^\\^\\^"
-  "HEAD^^^^^" "HEAD\\^\\^\\^\\^\\^"
-)
-
-magic-abbrev-expand () {
-  local MATCH
-  LBUFFER=${LBUFFER%%(#m)[-_a-zA-Z0-9^]#}
-  LBUFFER+=${abbreviations[$MATCH]:-$MATCH}
-}
-
-magic-abbrev-expand-and-insert () {
-  magic-abbrev-expand
-  zle self-insert
-}
-
-magic-abbrev-expand-and-accept () {
-  magic-abbrev-expand
-  zle accept-line
-}
-
-no-magic-abbrev-expand () {
-  LBUFFER+=' '
-}
-
-zle -N magic-abbrev-expand
-zle -N magic-abbrev-expand-and-insert
-zle -N magic-abbrev-expand-and-accept
-zle -N no-magic-abbrev-expand
-bindkey "\r"  magic-abbrev-expand-and-accept # M-x RET はできなくなる
-bindkey "^J"  accept-line # no magic
-bindkey " "   magic-abbrev-expand-and-insert
-bindkey "."   magic-abbrev-expand-and-insert
-bindkey "^x " no-magic-abbrev-expand
-
-# Incremental completion on zsh
-# http://mimosa-pudica.net/src/incr-0.2.zsh
-# やっぱりauto_menu使いたいのでoff
-# source ~/.zsh/incr*.zsh
-
-# auto-fuの設定。^PとかのHistory検索と相性が悪いのでひとまず無効に。
-# http://d.hatena.ne.jp/tarao/20100531/1275322620
-# incremental completion
-# if is-at-least 4.3.10; then
-    # function () { # precompile
-        # local A
-        # A=~/.zsh/auto-fu.zsh/auto-fu.zsh
-        # [[ -e "${A:r}.zwc" ]] && [[ "$A" -ot "${A:r}.zwc" ]] ||
-        # zsh -c "source $A; auto-fu-zcompile $A ${A:h}" >/dev/null 2>&1
-    # }
-    # source ~/.zsh/auto-fu.zsh/auto-fu; auto-fu-install
-    # function zle-line-init () { auto-fu-init }
-    # zle -N zle-line-init
-    # zstyle ':auto-fu:highlight' input bold
-    # zstyle ':auto-fu:highlight' completion fg=white
-    # zstyle ':auto-fu:var' postdisplay ''
-    # function afu+cancel () {
-        # afu-clearing-maybe
-        # ((afu_in_p == 1)) && { afu_in_p=0; BUFFER="$buffer_cur"; }
-    # }
-    # function bindkey-advice-before () {
-        # local key="$1"
-        # local advice="$2"
-        # local widget="$3"
-        # [[ -z "$widget" ]] && {
-            # local -a bind
-            # bind=(`bindkey -M main "$key"`)
-            # widget=$bind[2]
-        # }
-        # local fun="$advice"
-        # if [[ "$widget" != "undefined-key" ]]; then
-            # local code=${"$(<=(cat <<"EOT"
-                # function $advice-$widget () {
-                    # zle $advice
-                    # zle $widget
-                # }
-                # fun="$advice-$widget"
-# EOT
-            # ))"}
-            # eval "${${${code//\$widget/$widget}//\$key/$key}//\$advice/$advice}"
-        # fi
-        # zle -N "$fun"
-        # bindkey -M afu "$key" "$fun"
-    # }
-    # bindkey-advice-before "^G" afu+cancel
-    # bindkey-advice-before "^[" afu+cancel
-    # bindkey-advice-before "^J" afu+cancel afu+accept-line
-
-    # # delete unambiguous prefix when accepting line
-    # function afu+delete-unambiguous-prefix () {
-        # afu-clearing-maybe
-        # local buf; buf="$BUFFER"
-        # local bufc; bufc="$buffer_cur"
-        # [[ -z "$cursor_new" ]] && cursor_new=-1
-        # [[ "$buf[$cursor_new]" == ' ' ]] && return
-        # [[ "$buf[$cursor_new]" == '/' ]] && return
-        # ((afu_in_p == 1)) && [[ "$buf" != "$bufc" ]] && {
-            # # there are more than one completion candidates
-            # zle afu+complete-word
-            # [[ "$buf" == "$BUFFER" ]] && {
-                # # the completion suffix was an unambiguous prefix
-                # afu_in_p=0; buf="$bufc"
-            # }
-            # BUFFER="$buf"
-            # buffer_cur="$bufc"
-        # }
-    # }
-    # zle -N afu+delete-unambiguous-prefix
-    # function afu-ad-delete-unambiguous-prefix () {
-        # local afufun="$1"
-        # local code; code=$functions[$afufun]
-        # eval "function $afufun () { zle afu+delete-unambiguous-prefix; $code }"
-    # }
-    # afu-ad-delete-unambiguous-prefix afu+accept-line
-    # afu-ad-delete-unambiguous-prefix afu+accept-line-and-down-history
-    # afu-ad-delete-unambiguous-prefix afu+accept-and-hold
-# fi
-
-
-function rmf(){
-   for file in $*
-   do
-      __rm_single_file $file
-   done
-}
-
-function __rm_single_file(){
-       if ! [ -d ~/.Trash/ ]
-       then
-               command /bin/mkdir ~/.Trash
-       fi
-
-       if ! [ $# -eq 1 ]
-       then
-               echo "__rm_single_file: 1 argument required but $# passed."
-               exit
-       fi
-
-       if [ -e $1 ]
-       then
-               BASENAME=`basename $1`
-               NAME=$BASENAME
-               COUNT=0
-               while [ -e ~/.Trash/$NAME ]
-               do
-                       COUNT=$(($COUNT+1))
-                       NAME="$BASENAME.$COUNT"
-               done
-
-               command /bin/mv $1 ~/.Trash/$NAME
-       else
-               echo "No such file or directory: $file"
-       fi
-}
-
-## alias設定
-#
-[ -f ~/dotfiles/.zshrc.alias ] && source ~/dotfiles/.zshrc.alias
-
-case "${OSTYPE}" in
-# Mac(Unix)
-darwin*)
-    # ここに設定
-    [ -f ~/dotfiles/.zshrc.osx ] && source ~/dotfiles/.zshrc.osx
-    ;;
-# Linux
-linux*)
-    # ここに設定
-    [ -f ~/dotfiles/.zshrc.linux ] && source ~/dotfiles/.zshrc.linux
-    ;;
-esac
-
-
-## local固有設定
-#
-[ -f ~/.zshrc.local ] && source ~/.zshrc.local
+# Customize to your needs...
+source $HOME/.zshrc.custom
diff --git a/.zshrc.alias b/.zshrc.alias
index 75f97da..f2ef47b 100644
--- a/.zshrc.alias
+++ b/.zshrc.alias
@@ -77,6 +77,7 @@ alias gi='git'
 alias oppai='git'
 alias gs='git status -s -b'
 alias gst='git status -s -b'
+alias gst="git log --date=short --max-count=1 --pretty=format:'%Cgreen%h %cd %Cblue%cn%x09%Creset%s' | tail -1 && echo '' && git status -s -b"
 alias gc='git commit'
 alias gci='git commit -a'
 alias '偽ｔ'=git
@@ -95,30 +96,32 @@ alias scc='scalac -deprecation -unchecked -explaintypes'
 alias sci='scala -deprecation -unchecked -explaintypes -cp $SCALA_CLASSPATH -i ~/import.scala'
 alias sce='scala'

+# use oh-my-zsh/plugins/extract.zsh
+#
 # extract http://d.hatena.ne.jp/jeneshicc/20110215/1297778049
-extract () {
-  if [ -f $1 ] ; then
-      case $1 in
-          *.tar.bz2)   tar xvjf $1    ;;
-          *.tar.gz)    tar xvzf $1    ;;
-          *.tar.xz)    tar xvJf $1    ;;
-          *.bz2)       bunzip2 $1     ;;
-          *.rar)       unrar x $1     ;;
-          *.gz)        gunzip $1      ;;
-          *.tar)       tar xvf $1     ;;
-          *.tbz2)      tar xvjf $1    ;;
-          *.tgz)       tar xvzf $1    ;;
-          *.zip)       unzip $1       ;;
-          *.Z)         uncompress $1  ;;
-          *.7z)        7z x $1        ;;
-          *.lzma)      lzma -dv $1    ;;
-          *.xz)        xz -dv $1      ;;
-          *)           echo "don't know how to extract '$1'..." ;;
-      esac
-  else
-      echo "'$1' is not a valid file!"
-  fi
-}
+# extract () {
+  # if [ -f $1 ] ; then
+      # case $1 in
+          # *.tar.bz2)   tar xvjf $1    ;;
+          # *.tar.gz)    tar xvzf $1    ;;
+          # *.tar.xz)    tar xvJf $1    ;;
+          # *.bz2)       bunzip2 $1     ;;
+          # *.rar)       unrar x $1     ;;
+          # *.gz)        gunzip $1      ;;
+          # *.tar)       tar xvf $1     ;;
+          # *.tbz2)      tar xvjf $1    ;;
+          # *.tgz)       tar xvzf $1    ;;
+          # *.zip)       unzip $1       ;;
+          # *.Z)         uncompress $1  ;;
+          # *.7z)        7z x $1        ;;
+          # *.lzma)      lzma -dv $1    ;;
+          # *.xz)        xz -dv $1      ;;
+          # *)           echo "don't know how to extract '$1'..." ;;
+      # esac
+  # else
+      # echo "'$1' is not a valid file!"
+  # fi
+# }
 alias ex='extract'

 alias ev='vi ~/dotfiles/.vimrc*'
diff --git a/.zshrc.custom b/.zshrc.custom
new file mode 100644
index 0000000..0e7eddc
--- /dev/null
+++ b/.zshrc.custom
@@ -0,0 +1,686 @@
+# users generic .zshrc file for zsh(1)
+
+
+## Environment variable configuration
+#
+# LANG
+# http://curiousabt.blog27.fc2.com/blog-entry-65.html
+export LANG=ja_JP.UTF-8
+export LESSCHARSET=utf-8
+
+# oh-my-zsh export LESS=R
+unset LESS
+
+## Backspace key
+#
+bindkey "^?" backward-delete-char
+
+# プロンプトが表示されるたびにプロンプト文字列を評価、置換する
+setopt prompt_subst
+setopt transient_rprompt
+
+## Default shell configuration
+# colors enables us to idenfity color by $fg[red].
+autoload colors
+colors
+case ${UID} in
+0)
+    PROMPT="%B%{${fg[red]}%}%/#%{${reset_color}%}%b "
+    PROMPT2="%B%{${fg[red]}%}%_#%{${reset_color}%}%b "
+    SPROMPT="%B%{${fg[red]}%}%r is correct? [n,y,a,e]:%{${reset_color}%}%b "
+    [ -n "${REMOTEHOST}${SSH_CONNECTION}" ] &&
+        PROMPT="%{${fg[cyan]}%}$(echo ${HOST%%.*} | tr '[a-z]' '[A-Z]') ${PROMPT}"
+    ;;
+*)
+    #
+    # Color
+    #
+    DEFAULT=$'%{\e[1;0m%}'
+    RESET="%{${reset_color}%}"
+    GREEN="%{${fg[green]}%}"
+    BLUE="%{${fg[blue]}%}"
+    RED="%{${fg[red]}%}"
+    CYAN="%{${fg[cyan]}%}"
+    WHITE="%{${fg[white]}%}"
+    POH="( ꒪⌓꒪) $"
+
+    #
+    # Prompt
+    #
+    PROMPT='%{$fg_bold[blue]%}${USER}@%m ${RESET}${WHITE}${POH} ${RESET}'
+    RPROMPT='${RESET}${WHITE}[${BLUE}%(5~,%-2~/.../%2~,%~)% ${WHITE}]${RESET}'
+
+    #
+    # Vi入力モードでPROMPTの色を変える
+    # http://memo.officebrook.net/20090226.html
+    function zle-line-init zle-keymap-select {
+      case $KEYMAP in
+        vicmd)
+        PROMPT="%{$fg_bold[cyan]%}${USER}@%m ${RESET}${WHITE}${POH} ${RESET}"
+        ;;
+        main|viins)
+        PROMPT="%{$fg_bold[blue]%}${USER}@%m ${RESET}${WHITE}${POH} ${RESET}"
+        ;;
+      esac
+      zle reset-prompt
+    }
+    zle -N zle-line-init
+    zle -N zle-keymap-select
+
+    # Show git branch when you are in git repository
+    # http://d.hatena.ne.jp/mollifier/20100906/p1
+
+    autoload -Uz add-zsh-hook
+    autoload -Uz vcs_info
+
+    zstyle ':vcs_info:*' enable git svn hg bzr
+    zstyle ':vcs_info:*' formats '(%s)-[%b]'
+    zstyle ':vcs_info:*' actionformats '(%s)-[%b|%a]'
+    zstyle ':vcs_info:(svn|bzr):*' branchformat '%b:r%r'
+    zstyle ':vcs_info:bzr:*' use-simple true
+
+    autoload -Uz is-at-least
+    if is-at-least 4.3.10; then
+      # この check-for-changes が今回の設定するところ
+      zstyle ':vcs_info:git:*' check-for-changes true
+      zstyle ':vcs_info:git:*' stagedstr "+"    # 適当な文字列に変更する
+      zstyle ':vcs_info:git:*' unstagedstr "-"  # 適当の文字列に変更する
+      zstyle ':vcs_info:git:*' formats '(%s)-[%c%u%b]'
+      zstyle ':vcs_info:git:*' actionformats '(%s)-[%c%u%b|%a]'
+    fi
+
+    function _update_vcs_info_msg() {
+        psvar=()
+        LANG=en_US.UTF-8 vcs_info
+        psvar[2]=$(_git_not_pushed)
+        [[ -n "$vcs_info_msg_0_" ]] && psvar[1]="$vcs_info_msg_0_"
+    }
+    add-zsh-hook precmd _update_vcs_info_msg
+
+    # show status of git pushed to HEAD in prompt
+    function _git_not_pushed()
+    {
+      if [ "$(git rev-parse --is-inside-work-tree 2>/dev/null)" = "true" ]; then
+        head="$(git rev-parse HEAD)"
+        for x in $(git rev-parse --remotes)
+        do
+          if [ "$head" = "$x" ]; then
+            return 0
+          fi
+        done
+        echo "|?"
+      fi
+      return 0
+    }
+
+    # git のブランチ名 *と作業状態* を zsh の右プロンプトに表示＋ status に応じて色もつけてみた - Yarukidenized:ヤルキデナイズド :
+    # http://d.hatena.ne.jp/uasi/20091025/1256458798
+    autoload -Uz VCS_INFO_get_data_git; VCS_INFO_get_data_git 2> /dev/null
+
+    function rprompt-git-current-branch {
+      local name st color gitdir action pushed
+      if [[ "$PWD" =~ '/\.git(/.*)?$' ]]; then
+              return
+      fi
+
+      name=`git rev-parse --abbrev-ref=loose HEAD 2> /dev/null`
+      if [[ -z $name ]]; then
+              return
+      fi
+
+      gitdir=`git rev-parse --git-dir 2> /dev/null`
+      action=`VCS_INFO_git_getaction "$gitdir"` && action="|$action"
+      pushed="`_git_not_pushed`"
+
+      st=`git status 2> /dev/null`
+      if [[ "$st" =~ "(?m)^nothing to" ]]; then
+        color=%F{green}
+      elif [[ "$st" =~ "(?m)^nothing added" ]]; then
+        color=%F{yellow}
+      elif [[ "$st" =~ "(?m)^# Untracked" ]]; then
+        color=%B%F{red}
+      else
+        color=%F{red}
+      fi
+
+      echo "[$color$name$action$pushed%f%b]"
+    }
+
+    # PCRE 互換の正規表現を使う
+    setopt re_match_pcre
+
+    RPROMPT='`rprompt-git-current-branch`${RESET}${WHITE}[${BLUE}%(5~,%-2~/.../%2~,%~)${WHITE}]${RESET}'
+
+    ;;
+esac
+
+# 指定したコマンド名がなく、ディレクトリ名と一致した場合 cd する
+setopt auto_cd
+
+# cd でTabを押すとdir list を表示
+setopt auto_pushd
+
+# ディレクトリスタックに同じディレクトリを追加しないようになる
+setopt pushd_ignore_dups
+
+# コマンドのスペルチェックをする
+setopt correct
+
+# コマンドライン全てのスペルチェックをする
+setopt correct_all
+
+# 上書きリダイレクトの禁止
+setopt no_clobber
+
+# 補完候補リストを詰めて表示
+setopt list_packed
+
+# auto_list の補完候補一覧で、ls -F のようにファイルの種別をマーク表示
+setopt list_types
+
+# 補完候補が複数ある時に、一覧表示する
+setopt auto_list
+
+# コマンドラインの引数で --prefix=/usr などの = 以降でも補完できる
+setopt magic_equal_subst
+
+# カッコの対応などを自動的に補完する
+setopt auto_param_keys
+
+# ディレクトリ名の補完で末尾の / を自動的に付加し、次の補完に備える
+setopt auto_param_slash
+
+# {a-c} を a b c に展開する機能を使えるようにする
+setopt brace_ccl
+
+# シンボリックリンクは実体を追うようになる
+#setopt chase_links
+
+# 補完キー（Tab,  Ctrl+I) を連打するだけで順に補完候補を自動で補完する
+setopt auto_menu
+
+# sudoも補完の対象
+zstyle ':completion:*:sudo:*' command-path /usr/local/sbin /usr/local/bin /usr/sbin /usr/bin /sbin /bin
+
+# 色付きで補完する
+zstyle ':completion:*' list-colors di=34 fi=0
+#zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
+
+# 複数のリダイレクトやパイプなど、必要に応じて tee や cat の機能が使われる
+setopt multios
+
+# 最後がディレクトリ名で終わっている場合末尾の / を自動的に取り除かない
+setopt noautoremoveslash
+
+# beepを鳴らさないようにする
+setopt nolistbeep
+
+# Match without pattern
+# ex. > rm *~398
+# remove * without a file "398". For test, use "echo *~398"
+setopt extended_glob
+
+## Keybind configuration
+#
+# emacs like keybind (e.x. Ctrl-a goes to head of a line and Ctrl-e goes
+#   to end of it)
+#
+bindkey -v
+
+# historical backward/forward search with linehead string binded to ^P/^N
+#
+autoload history-search-end
+zle -N history-beginning-search-backward-end history-search-end
+zle -N history-beginning-search-forward-end history-search-end
+bindkey "^p" history-beginning-search-backward-end
+bindkey "^n" history-beginning-search-forward-end
+bindkey "\\ep" history-beginning-search-backward-end
+bindkey "\\en" history-beginning-search-forward-end
+
+# glob(*)によるインクリメンタルサーチ
+bindkey '^R' history-incremental-pattern-search-backward
+bindkey '^S' history-incremental-pattern-search-forward
+
+## Command history configuration
+HISTFILE=~/.zsh_history
+HISTSIZE=10000
+SAVEHIST=10000
+
+# 登録済コマンド行は古い方を削除
+setopt hist_ignore_all_dups
+
+# historyの共有
+setopt share_history
+
+# 余分な空白は詰める
+setopt hist_reduce_blanks
+
+# add history when command executed.
+setopt inc_append_history
+
+# history (fc -l) コマンドをヒストリリストから取り除く。
+setopt hist_no_store
+# サスペンド中のプロセスと同じコマンド名を実行した場合はリジュームする
+#setopt auto_resume
+
+# =command を command のパス名に展開する
+#setopt equals
+
+# ファイル名で #, ~, ^ の 3 文字を正規表現として扱う
+#setopt extended_glob
+
+# zsh の開始・終了時刻をヒストリファイルに書き込む
+#setopt extended_history
+
+# Ctrl+S/Ctrl+Q によるフロー制御を使わないようにする
+#setopt NO_flow_control
+
+# 各コマンドが実行されるときにパスをハッシュに入れる
+#setopt hash_cmds
+
+# コマンドラインの先頭がスペースで始まる場合ヒストリに追加しない
+#setopt hist_ignore_space
+
+# ヒストリを呼び出してから実行する間に一旦編集できる状態になる
+#setopt hist_verify
+
+# シェルが終了しても裏ジョブに HUP シグナルを送らないようにする
+#setopt NO_hup
+
+# Ctrl+D では終了しないようになる（exit, logout などを使う）
+#setopt ignore_eof
+
+# コマンドラインでも # 以降をコメントと見なす
+#setopt interactive_comments
+
+# メールスプール $MAIL が読まれていたらワーニングを表示する
+#setopt mail_warning
+
+# ファイル名の展開でディレクトリにマッチした場合末尾に / を付加する
+#setopt mark_dirs
+
+# ファイル名の展開で、辞書順ではなく数値的にソートされるようになる
+#setopt numeric_glob_sort
+
+# コマンド名に / が含まれているとき PATH 中のサブディレクトリを探す
+setopt path_dirs
+
+# 戻り値が 0 以外の場合終了コードを表示する
+# setopt print_exit_value
+
+# pushd を引数なしで実行した場合 pushd $HOME と見なされる
+#setopt pushd_to_home
+
+# rm * などの際、本当に全てのファイルを消して良いかの確認しないようになる
+#setopt rm_star_silent
+
+# rm_star_silent の逆で、10 秒間反応しなくなり、頭を冷ます時間が与えられる
+#setopt rm_star_wait
+
+# for, repeat, select, if, function などで簡略文法が使えるようになる
+#setopt short_loops
+
+# デフォルトの複数行コマンドライン編集ではなく、１行編集モードになる
+#setopt single_line_zle
+
+# コマンドラインがどのように展開され実行されたかを表示するようになる
+#setopt xtrace
+
+# ^でcd ..する
+function cdup() {
+echo
+cd ..
+zle reset-prompt
+}
+zle -N cdup
+# bindkey '\^' cdup
+
+# ctrl-w, ctrl-bキーで単語移動
+bindkey "^W" forward-word
+bindkey "^B" backward-word
+
+# back-wordでの単語境界の設定
+autoload -Uz select-word-style
+select-word-style default
+zstyle ':zle:*' word-chars " _-./;@"
+zstyle ':zle:*' word-style unspecified
+
+# URLをコピペしたときに自動でエスケープ
+autoload -Uz url-quote-magic
+zle -N self-insert url-quote-magic
+
+# 勝手にpushd
+setopt autopushd
+
+# エラーメッセージ本文出力に色付け
+e_normal=`echo -e "¥033[0;30m"`
+e_RED=`echo -e "¥033[1;31m"`
+e_BLUE=`echo -e "¥033[1;36m"`
+
+function make() {
+    LANG=C command make "$@" 2>&1 | sed -e "s@[Ee]rror:.*@$e_RED&$e_normal@g" -e "s@cannot¥sfind.*@$e_RED&$e_normal@g" -e "s@[Ww]arning:.*@$e_BLUE&$e_normal@g"
+}
+function cwaf() {
+    LANG=C command ./waf "$@" 2>&1 | sed -e "s@[Ee]rror:.*@$e_RED&$e_normal@g" -e "s@cannot¥sfind.*@$e_RED&$e_normal@g" -e "s@[Ww]arning:.*@$e_BLUE&$e_normal@g"
+}
+
+## Completion configuration
+#
+fpath=(~/.zsh/functions/Completion ${fpath})
+autoload -U compinit
+compinit -u
+
+
+## zsh editor
+#
+autoload zed
+
+
+## Prediction configuration
+#
+autoload predict-on
+#predict-off
+
+## Command Line Stack [Esc]-[q]
+bindkey -a 'q' push-line
+
+
+## Alias configuration
+#
+# expand aliases before completing
+#
+setopt complete_aliases     # aliased ls needs if file/dir completions work
+
+alias where="command -v"
+
+case "${OSTYPE}" in
+freebsd*|darwin*)
+    alias ls="ls -alG"
+    zle -N expand-to-home-or-insert
+    bindkey "@"  expand-to-home-or-insert
+    ;;
+linux*)
+    alias la="ls -al"
+    ;;
+esac
+
+
+case "${OSTYPE}" in
+# MacOSX
+darwin*)
+    export PATH=$PATH:/opt/local/bin:/opt/local/sbin/
+    export PATH=$PATH:/System/Library/PrivateFrameworks/Apple80211.framework/Versions/A/Resources/
+    ;;
+freebsd*)
+    case ${UID} in
+    0)
+        updateports()
+        {
+            if [ -f /usr/ports/.portsnap.INDEX ]
+            then
+                portsnap fetch update
+            else
+                portsnap fetch extract update
+            fi
+            (cd /usr/ports/; make index)
+
+            portversion -v -l \<
+        }
+        alias appsupgrade='pkgdb -F && BATCH=YES NO_CHECKSUM=YES portupgrade -a'
+        ;;
+    esac
+    ;;
+esac
+
+
+## terminal configuration
+# http://journal.mycom.co.jp/column/zsh/009/index.html
+unset LSCOLORS
+
+case "${TERM}" in
+xterm)
+    export TERM=xterm-color
+
+    ;;
+kterm)
+    export TERM=kterm-color
+    # set BackSpace control character
+
+    stty erase
+    ;;
+
+cons25)
+    unset LANG
+  export LSCOLORS=ExFxCxdxBxegedabagacad
+
+    export LS_COLORS='di=01;32:ln=01;35:so=01;32:ex=01;31:bd=46;34:cd=43;34:su=41;30:sg=46;30'
+    zstyle ':completion:*' list-colors \
+        'di=;36;1' 'ln=;35;1' 'so=;32;1' 'ex=31;1' 'bd=46;34' 'cd=43;34'
+    ;;
+
+kterm*|xterm*)
+   # Terminal.app
+#    precmd() {
+#        echo -ne "\033]0;${USER}@${HOST%%.*}:${PWD}\007"
+#    }
+    # export LSCOLORS=exfxcxdxbxegedabagacad
+    # export LSCOLORS=gxfxcxdxbxegedabagacad
+    # export LS_COLORS='di=1;34:ln=35:so=32:pi=33:ex=31:bd=46;34:cd=43;34:su=41;30:sg=46;30'
+
+    export CLICOLOR=1
+    export LSCOLORS=ExFxCxDxBxegedabagacad
+
+    zstyle ':completion:*' list-colors \
+        'di=36' 'ln=35' 'so=32' 'ex=31' 'bd=46;34' 'cd=43;34'
+    ;;
+
+dumb)
+    echo "Welcome Emacs Shell"
+    ;;
+esac
+
+
+
+export EDITOR=vim
+export PATH=$PATH:$HOME/local/bin:/usr/local/git/bin
+export PATH=$PATH:$HOME/dotfiles/bin
+export PATH=$PATH:/sbin:/usr/local/bin
+export MANPATH=$MANPATH:/opt/local/man:/usr/local/share/man
+
+expand-to-home-or-insert () {
+        if [ "$LBUFFER" = "" -o "$LBUFFER[-1]" = " " ]; then
+                LBUFFER+="~/"
+        else
+                zle self-insert
+        fi
+}
+
+# C-M-h でチートシートを表示する
+cheat-sheet () { zle -M "`cat ~/dotfiles/.zsh/cheat-sheet`" }
+zle -N cheat-sheet
+# bindkey "^[^h" cheat-sheet
+
+# zsh の exntended_glob と HEAD^^^ を共存させる。
+# http://subtech.g.hatena.ne.jp/cho45/20080617/1213629154
+typeset -A abbreviations
+abbreviations=(
+  "L"    "| $PAGER"
+  "G"    "| grep"
+
+  "HEAD^"     "HEAD\\^"
+  "HEAD^^"    "HEAD\\^\\^"
+  "HEAD^^^"   "HEAD\\^\\^\\^"
+  "HEAD^^^^"  "HEAD\\^\\^\\^\\^\\^"
+  "HEAD^^^^^" "HEAD\\^\\^\\^\\^\\^"
+)
+
+magic-abbrev-expand () {
+  local MATCH
+  LBUFFER=${LBUFFER%%(#m)[-_a-zA-Z0-9^]#}
+  LBUFFER+=${abbreviations[$MATCH]:-$MATCH}
+}
+
+magic-abbrev-expand-and-insert () {
+  magic-abbrev-expand
+  zle self-insert
+}
+
+magic-abbrev-expand-and-accept () {
+  magic-abbrev-expand
+  zle accept-line
+}
+
+no-magic-abbrev-expand () {
+  LBUFFER+=' '
+}
+
+zle -N magic-abbrev-expand
+zle -N magic-abbrev-expand-and-insert
+zle -N magic-abbrev-expand-and-accept
+zle -N no-magic-abbrev-expand
+bindkey "\r"  magic-abbrev-expand-and-accept # M-x RET はできなくなる
+bindkey "^J"  accept-line # no magic
+bindkey " "   magic-abbrev-expand-and-insert
+bindkey "."   magic-abbrev-expand-and-insert
+bindkey "^x " no-magic-abbrev-expand
+
+# Incremental completion on zsh
+# http://mimosa-pudica.net/src/incr-0.2.zsh
+# やっぱりauto_menu使いたいのでoff
+# source ~/.zsh/incr*.zsh
+
+# auto-fuの設定。^PとかのHistory検索と相性が悪いのでひとまず無効に。
+# http://d.hatena.ne.jp/tarao/20100531/1275322620
+# incremental completion
+# if is-at-least 4.3.10; then
+    # function () { # precompile
+        # local A
+        # A=~/.zsh/auto-fu.zsh/auto-fu.zsh
+        # [[ -e "${A:r}.zwc" ]] && [[ "$A" -ot "${A:r}.zwc" ]] ||
+        # zsh -c "source $A; auto-fu-zcompile $A ${A:h}" >/dev/null 2>&1
+    # }
+    # source ~/.zsh/auto-fu.zsh/auto-fu; auto-fu-install
+    # function zle-line-init () { auto-fu-init }
+    # zle -N zle-line-init
+    # zstyle ':auto-fu:highlight' input bold
+    # zstyle ':auto-fu:highlight' completion fg=white
+    # zstyle ':auto-fu:var' postdisplay ''
+    # function afu+cancel () {
+        # afu-clearing-maybe
+        # ((afu_in_p == 1)) && { afu_in_p=0; BUFFER="$buffer_cur"; }
+    # }
+    # function bindkey-advice-before () {
+        # local key="$1"
+        # local advice="$2"
+        # local widget="$3"
+        # [[ -z "$widget" ]] && {
+            # local -a bind
+            # bind=(`bindkey -M main "$key"`)
+            # widget=$bind[2]
+        # }
+        # local fun="$advice"
+        # if [[ "$widget" != "undefined-key" ]]; then
+            # local code=${"$(<=(cat <<"EOT"
+                # function $advice-$widget () {
+                    # zle $advice
+                    # zle $widget
+                # }
+                # fun="$advice-$widget"
+# EOT
+            # ))"}
+            # eval "${${${code//\$widget/$widget}//\$key/$key}//\$advice/$advice}"
+        # fi
+        # zle -N "$fun"
+        # bindkey -M afu "$key" "$fun"
+    # }
+    # bindkey-advice-before "^G" afu+cancel
+    # bindkey-advice-before "^[" afu+cancel
+    # bindkey-advice-before "^J" afu+cancel afu+accept-line
+
+    # # delete unambiguous prefix when accepting line
+    # function afu+delete-unambiguous-prefix () {
+        # afu-clearing-maybe
+        # local buf; buf="$BUFFER"
+        # local bufc; bufc="$buffer_cur"
+        # [[ -z "$cursor_new" ]] && cursor_new=-1
+        # [[ "$buf[$cursor_new]" == ' ' ]] && return
+        # [[ "$buf[$cursor_new]" == '/' ]] && return
+        # ((afu_in_p == 1)) && [[ "$buf" != "$bufc" ]] && {
+            # # there are more than one completion candidates
+            # zle afu+complete-word
+            # [[ "$buf" == "$BUFFER" ]] && {
+                # # the completion suffix was an unambiguous prefix
+                # afu_in_p=0; buf="$bufc"
+            # }
+            # BUFFER="$buf"
+            # buffer_cur="$bufc"
+        # }
+    # }
+    # zle -N afu+delete-unambiguous-prefix
+    # function afu-ad-delete-unambiguous-prefix () {
+        # local afufun="$1"
+        # local code; code=$functions[$afufun]
+        # eval "function $afufun () { zle afu+delete-unambiguous-prefix; $code }"
+    # }
+    # afu-ad-delete-unambiguous-prefix afu+accept-line
+    # afu-ad-delete-unambiguous-prefix afu+accept-line-and-down-history
+    # afu-ad-delete-unambiguous-prefix afu+accept-and-hold
+# fi
+
+
+function rmf(){
+   for file in $*
+   do
+      __rm_single_file $file
+   done
+}
+
+function __rm_single_file(){
+       if ! [ -d ~/.Trash/ ]
+       then
+               command /bin/mkdir ~/.Trash
+       fi
+
+       if ! [ $# -eq 1 ]
+       then
+               echo "__rm_single_file: 1 argument required but $# passed."
+               exit
+       fi
+
+       if [ -e $1 ]
+       then
+               BASENAME=`basename $1`
+               NAME=$BASENAME
+               COUNT=0
+               while [ -e ~/.Trash/$NAME ]
+               do
+                       COUNT=$(($COUNT+1))
+                       NAME="$BASENAME.$COUNT"
+               done
+
+               command /bin/mv $1 ~/.Trash/$NAME
+       else
+               echo "No such file or directory: $file"
+       fi
+}
+
+## alias設定
+#
+[ -f ~/dotfiles/.zshrc.alias ] && source ~/dotfiles/.zshrc.alias
+
+case "${OSTYPE}" in
+# MacOSX
+darwin*)
+    # ここに設定
+    [ -f ~/dotfiles/.zshrc.osx ] && source ~/dotfiles/.zshrc.osx
+    ;;
+# Linux
+linux*)
+    # ここに設定
+    [ -f ~/dotfiles/.zshrc.linux ] && source ~/dotfiles/.zshrc.linux
+    ;;
+esac
+
+## local固有設定
+#
+[ -f ~/.zshrc.local ] && source ~/.zshrc.local
diff --git a/.zshrc.osx b/.zshrc.osx
index 88dd6f2..f3db216 100644
--- a/.zshrc.osx
+++ b/.zshrc.osx
@@ -26,6 +26,8 @@ export PATH=$JAVA_HOME/bin:$PATH
 # デフォルトエンコーディングSJISをUTF-8へ
 export _JAVA_OPTIONS="-Dfile.encoding=UTF-8"

+# haskell
+export PATH=/Users/ozaki/Library/Haskell/bin:$PATH

 # scala
 export SCALA_HOME=/Users/ozaki/.svm/current/rt
diff --git a/bin/git-switch b/bin/git-switch
new file mode 100755
index 0000000..2dd7df5
--- /dev/null
+++ b/bin/git-switch
@@ -0,0 +1,78 @@
+#!/usr/bin/env ruby
+# -*- coding: utf-8 -*-
+
+require 'optparse'
+
+@hard = false
+opt_parser = OptionParser.new{|opts|
+  opts.banner = 'git switch [--hard] [--repository=<path>] [--new-workdir=<path>] <branch> <command...>'
+  opts.on("--hard",        'execute `git reset --hard` before switch to branch'){ @hard == true}
+  opts.on("--repository",  "target repository.(default is current repository)"){|v| @repository = v}
+  opts.on("--new-workdir", "path to the new working directory.(default /tmp/<repsitory_name>)"){|v| @new_work_dir = v}
+}
+
+args = ARGV.dup
+opt_parser.order!(args)
+@branch = args.shift
+@command = args
+
+unless @branch && @command && @command.length > 0
+  puts opt_parser.banner
+  exit 128
+end
+
+unless @repository
+  @repository = `git rev-parse -q --show-toplevel`.chomp
+end
+
+unless File.exists?(@repository)
+  puts "No such repository: #{@repository}"
+  exit 128
+end
+
+unless @new_work_dir
+  @new_work_dir = "/tmp/#{File.basename(@repository)}"
+end
+
+unless File.exists?(@new_work_dir)
+  res = system("git-new-workdir #{@repository} #{@new_work_dir} ")
+  exit 128 unless res
+  puts "git-new-workdir #{@repository} #{@new_work_dir} "
+end
+
+if @hard
+  res = system("git reset --hard HEAD")
+  exit 128 unless res
+end
+
+Dir.chdir(@new_work_dir){
+  res = system("git checkout #{@branch}")
+  exit 128 unless res
+
+  pid = fork do
+    exec(*@command)
+  end
+
+  if pid
+    # TODO signal handling
+    # force terminate child process
+    [:INT, :TERM, :KILL, :CHLD, :QUIT].each do |sig|
+      Signal.trap(sig){
+        catch(:done) {
+          [:INT, :CHLD, :KILL, :QUIT].each do |s|
+            begin
+              Process.kill(s, pid)
+            rescue Errno::ECHILD
+              throw :done
+            rescue Errno::ESRCH
+              throw :done
+            end
+          end
+        }
+      }
+    end
+  end
+
+  Process.wait
+}
+
diff --git a/setup.sh b/setup.sh
index 95ae71a..c7f438e 100755
--- a/setup.sh
+++ b/setup.sh
@@ -1,9 +1,12 @@
 #!/bin/bash

-DOT_FILES=( .zsh .zshrc .zshrc.alias .zshrc.linux .zshrc.osx .ctags .emacs.el .gdbinit .gemrc .gitconfig .gitignore .inputrc .irbrc .sbtconfig .screenrc .vimrc .vim .vrapperrc import.scala .tmux.conf .dir_colors .rdebugrc .pryrc)
+DOT_FILES=( .zsh .zshrc .zshrc.custom .zshrc.alias .zshrc.linux .zshrc.osx .ctags .emacs.el .gdbinit .gemrc .gitconfig .gitignore .inputrc .irbrc .sbtconfig .screenrc .vimrc .vim .vrapperrc import.scala .tmux.conf .dir_colors .rdebugrc .pryrc)

 for file in ${DOT_FILES[@]}
 do
     ln -s $HOME/dotfiles/$file $HOME/$file
 done

+# install oh-my-zsh
+[! -d ~/.oh-my-zsh ] && git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh
+
hogehoge
hogehoge