This file contains hidden or 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
#! /bin/bash | |
# usage: tssh <ssh_target> <tmux target> [<ssh args>] | |
# requires ssh passwordless login to be setup and tmux to be installed on the remote machine | |
set -eu | |
# Count the number of args passed through, if there are not enough print the help. | |
if [[ "$#" < "2" ]]; then | |
echo "Not enough arguments where passed to the script." | |
echo "Usage: $0 <ssh_target> <tmux target> [<ssh args>]" |