diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2013-09-14 17:04:05 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2013-09-14 17:42:03 +1200 |
commit | 604de244454bae91ac073360b95ac8d52e52a39c (patch) | |
tree | d033cf0de74d0c4b8837394d4fc6f0819096f60b /psshd | |
parent | Loop through commands rather than repeating (diff) | |
download | psshd-604de244454bae91ac073360b95ac8d52e52a39c.tar.gz psshd-604de244454bae91ac073360b95ac8d52e52a39c.zip |
Use consistent if/for/while block syntax
Diffstat (limited to 'psshd')
-rwxr-xr-x | psshd | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -30,8 +30,7 @@ for cmd in "${cmds[@]}"; do done # Get port in options -while getopts ':p:' opt -do +while getopts ':p:' opt; do case "$opt" in p) port="$OPTARG" @@ -49,8 +48,7 @@ done shift "$((OPTIND-1))" # If no port, give up with usage instructions -if [[ ! -n "$port" ]] -then +if [[ ! -n "$port" ]]; then printf "USAGE: $0 -p <port number> -- <ssh arguments>\n" exit 1 fi |