1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-11-25 15:20:08 +00:00

Tmux plugin now just runs tmux if any extra args are given.

This commit is contained in:
Josh Matthews 2013-02-26 18:07:25 -05:00
parent 3aef6793c2
commit 778ae57772

View file

@ -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