Skip to content

Commit

Permalink
tmux list sessions only in interactive shells
Browse files Browse the repository at this point in the history
  • Loading branch information
wtfleming committed Jun 5, 2015
1 parent 1fe23f8 commit 277fb6c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Dotfiles/bashrc
Expand Up @@ -74,8 +74,12 @@ export PATH="$HOME/.rbenv/plugins/ruby-build/bin:$PATH"

PATH=$PATH:$HOME/bin/elastic-mapreduce-ruby

# List tmux sessions on login. If none, don't show the error.
tmux list-sessions 2> /dev/null
# Only run this tmux command in an interactive shell
# since it writes to stdout, which breaks scp
case "$-" in
# List tmux sessions on login. If none, don't show the error.
*i*) tmux list-sessions 2> /dev/null
esac

[[ -e ~/.git-completion.bash ]] && source ~/.git-completion.bash
[[ -e ~/.git-prompt.sh ]] && source ~/.git-prompt.sh
Expand Down

0 comments on commit 277fb6c

Please sign in to comment.