diff options
author | Josh Matthews <jmatth@nbcs.rutgers.edu> | 2013-02-26 18:07:25 -0500 |
---|---|---|
committer | Josh Matthews <jmatth@nbcs.rutgers.edu> | 2013-02-26 22:29:26 -0500 |
commit | 778ae57772a02d11c393708c4c0644fbd1ffac35 (patch) | |
tree | 374674b220514ade4b8568f49631f5f4d1415556 /plugins | |
parent | 3aef6793c2bf0c0afec1fdb97a3a56e7f8d065c6 (diff) | |
download | zsh-778ae57772a02d11c393708c4c0644fbd1ffac35.tar.gz zsh-778ae57772a02d11c393708c4c0644fbd1ffac35.tar.bz2 zsh-778ae57772a02d11c393708c4c0644fbd1ffac35.zip |
Tmux plugin now just runs tmux if any extra args are given.
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/tmux/tmux.plugin.zsh | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/tmux/tmux.plugin.zsh b/plugins/tmux/tmux.plugin.zsh index f67c2b8b5..d8fdd9255 100644 --- a/plugins/tmux/tmux.plugin.zsh +++ b/plugins/tmux/tmux.plugin.zsh @@ -36,7 +36,12 @@ fi # Override tmux with our function function zsh_tmux_plugin_start() { - if [[ "$ZSH_TMUX_AUTOCONNECT" == "true" ]] + # We have other arguments, just run them + if [[ ! -n "$@" ]] + then + \tmux $@ + # Try to connect to an existing session. + elif [[ "$ZSH_TMUX_AUTOCONNECT" == "true" ]] then \tmux attach || tmux -f $fixed_config new-session [[ "$ZSH_TMUX_AUTOQUIT" == "true" ]] && exit |