Created
February 23, 2023 10:41
-
-
Save erenkeskin/7658a63cf944328cb3d28a1e4f3fed6f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s0="0" | |
s1="1" | |
selectedS=$s0 | |
s=$1 | |
if [ $s -eq 0 ]; then | |
selectedS=$s0 | |
elif [ $s -eq 1 ]; then | |
selectedS=$s1 | |
else | |
echo "This number is not valid" | |
exit 1 | |
fi | |
tmux new -s ssh_tmux -d | |
tmux select-pane -t 0 | |
tmux splitw -h -p 25 -t | |
tmux splitw -h -p 25 -t | |
tmux select-pane -t 1 | |
tmux splitw -v | |
tmux select-pane -t 3 | |
tmux splitw -v | |
tmux select-pane -t 0 | |
tmux splitw -v | |
tmux select-pane -t 0 | |
tmux send-keys 'ssh name@'$selectedS Enter | |
tmux select-pane -t 1 | |
tmux send-keys 'ssh name@'$selectedS Enter | |
tmux select-pane -t 2 | |
tmux send-keys 'ssh name@'$selectedS Enter | |
tmux select-pane -t 3 | |
tmux send-keys 'ssh name@'$selectedS Enter | |
tmux select-pane -t 4 | |
tmux send-keys 'ssh name@'$selectedS Enter | |
tmux select-pane -t 5 | |
tmux send-keys 'ssh name@'$selectedS Enter | |
tmux attach -t ssh_tmux |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment