From 778ae57772a02d11c393708c4c0644fbd1ffac35 Mon Sep 17 00:00:00 2001 From: Josh Matthews Date: Tue, 26 Feb 2013 18:07:25 -0500 Subject: [PATCH] Tmux plugin now just runs tmux if any extra args are given. --- plugins/tmux/tmux.plugin.zsh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) 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