Skip to content

Commit

Permalink
Improve readability
Browse files Browse the repository at this point in the history
  • Loading branch information
rdavid committed Jan 9, 2024
1 parent f99f053 commit 63661ea
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions app/tru
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# shellcheck disable=SC3043 # Uses local variables.
# shellcheck disable=SC1091,SC2034 # File not following, appears unused.
readonly \
BASE_APP_VERSION=0.9.20240105 \
BASE_APP_VERSION=0.9.20240109 \
BASE_MIN_VERSION=0.9.20240104
. base.sh

Expand Down Expand Up @@ -64,12 +64,8 @@ validation() {
validate_cmd awk nc tr transmission-remote transmission-show
[ "$#" -eq 3 ] || die Usage: tru host:port user:pass torrent-file.

# Single : means there is no authentication data.
if [ "$2" != : ]; then
AUT="--auth $2"
else
AUT=''
fi
# Single ':' means there is no authentication data.
[ "$2" != : ] && AUT="--auth $2" || AUT=''
readonly \
AUT \
SER="$1" \
Expand Down

0 comments on commit 63661ea

Please sign in to comment.