diff --git a/extras/get-plex-token b/extras/get-plex-token index a01f207..611a1fc 100755 --- a/extras/get-plex-token +++ b/extras/get-plex-token @@ -4,9 +4,9 @@ URL_LOGIN='https://plex.tv/users/sign_in.json' getPlexToken() { if [ -n "$TOKEN" ]; then - echo "Fetching token from config" + [ "$VERBOSE" = "yes" ] && echo "Fetching token from config" elif getPlexServerToken; then - echo "Fetching token from Plex server" + [ "$VERBOSE" = "yes" ] && echo "Fetching token from Plex server" elif [ -z "$TOKEN" -a -n "$EMAIL" -a -n "$PASS" ]; then #TOFIX echo "WARNING: Storing your email and password has been deprecated. Please re-run extras/installer.sh or see LINK_TO_FAQ." @@ -121,6 +121,8 @@ getPlexWebToken() { # Clean up temp files since they may contain sensitive information rm "${FILE_FAILCAUSE}" "${FILE_POSTDATA}" "${FILE_RAW}" + + [ -n "$TOKEN" ] # simulate exit status } if [ "$(basename "$0")" = "get-plex-token" ]; then diff --git a/extras/installer.sh b/extras/installer.sh index e5f507c..b59273a 100755 --- a/extras/installer.sh +++ b/extras/installer.sh @@ -5,6 +5,7 @@ FULL_PATH="/opt/plexupdate" CONFIGFILE="/etc/plexupdate.conf" CONFIGCRON="/etc/plexupdate.cron.conf" CRONWRAPPER="/etc/cron.daily/plexupdate" +VERBOSE=yes #to be inherited by get-plex-token, do not save to config # default options AUTOINSTALL=yes diff --git a/plexupdate.sh b/plexupdate.sh index 825ea70..c42ad16 100755 --- a/plexupdate.sh +++ b/plexupdate.sh @@ -495,7 +495,7 @@ if [ "${CHECKONLY}" = "yes" ]; then info "Your OS reports Plex $INSTALLED_VERSION installed, newer version is available (${AVAIL})" exit 7 else - info "You are running latest version of Plex (${INSTALLED_VERSION})" + info "You are running the latest version of Plex (${INSTALLED_VERSION})" fi exit 0 fi