Created
May 8, 2014 19:09
-
-
Save changemewtf/daaf02b5beeb2ac03efa to your computer and use it in GitHub Desktop.
baffling tmux titles
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### ~/.tmux.conf ### | |
set-option -g default-command "tmux rename-window bash; reattach-to-user-namespace -l bash" | |
### ~/bin/tmux-project ### | |
#!/bin/bash | |
export SESSION=$(basename $PWD) | |
# set window title | |
echo -ne "\033]0;${SESSION}\007" | |
tmux new-session -s $SESSION \; source-file ~/.common-public/sh/.tmux-project.tmux | |
### ~/.common-public/sh/.tmux-project.tmux ### | |
unbind-key q | |
bind-key q send-keys -t lib ":Q" C-m \; kill-session | |
set-window-option -g automatic-rename off | |
rename-window git | |
send-keys "git status" C-m | |
new-window -n lib | |
send-keys "if [ -e .session.vim ]; then vim -S .session.vim; else vim; fi" C-m | |
new-window -n bash | |
select-window -t git |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment