Skip to content
Browse files

mac用のtmux周りのやつ

  • Loading branch information...
1 parent 3ae8037 commit 39436f7ad0347f4a559c79140d28cf817ae8121d @mironal committed
Showing with 15 additions and 6 deletions.
  1. +0 −1 .gitignore
  2. +0 −5 .vimrc
  3. BIN bin/reattach-to-user-namespace
  4. +15 −0 bin/tmuxx
View
1 .gitignore
@@ -24,7 +24,6 @@
.vim/bundle
.gitconfig
app
-bin
bkup
doc
src
View
5 .vimrc
@@ -53,11 +53,6 @@ let g:neocomplcache_dictionary_filetype_lists = {
\ 'vim' : $HOME . '/.vim/dict/vim.dict',
\ 'vimshell' : $HOME . '/.vimshell/command-history',
\ }
-map <C-g> :Gtags
-map <C-f> :Gtags -f %<CR>
-map <C-j> :GtagsCursor<CR>
-map <C-n> :cn<CR>
-map <C-p> :cp<CR>
set nocompatible
filetype off
View
BIN bin/reattach-to-user-namespace
Binary file not shown.
View
15 bin/tmuxx
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+SHELL=/bin/zsh
+## attach to an existing tmux session, or create one if none exist
+## also set up access to the system clipboard from within tmux when possible
+
+if [[ ( $OSTYPE == darwin* ) && ( -x $(which reattach-to-user-namespace 2>/dev/null) ) ]]; then
+ # on OS X force tmux's default command to spawn a shell in the user's namespace
+ # https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard
+ tweaked_config=$(cat $HOME/.tmux.conf <(echo 'set-option -g default-command "reattach-to-user-namespace -l $SHELL"'))
+
+ tmux attach || tmux -f <(echo "$tweaked_config") new-session
+else
+ tmux attach || tmux new-session
+fi

0 comments on commit 39436f7

Please sign in to comment.
Something went wrong with that request. Please try again.