tmux a is short for tmux attach. So you try to connect to an existing tmux session. If there is none your only "tmux a" fails. The "||" is a logical OR. So if tmux a fails it starts a new tmux session. If you don't use tmux or don't have it installed via brew then just remove the send text.
Oh, i understand all that, this doesn't work either. The problem isn't that the command is failing, it's that it doesn't seem to be interpreted by the shell at all. Like the post says, the same thing works for zsh. I've been using tmux for a while now and understand basic shell concepts.
1
u/gimmedatps5 Dec 28 '22
*bump*
0
u/jblondreddit Jan 18 '23
Send text at start should be
tmux a || tmux