mirror of
https://github.com/mrworf/plexupdate.git
synced 2025-08-20 21:33:16 -07:00
Remove -S option. Closes #85
This commit is contained in:
parent
10b7a1c4bf
commit
6e8686ed1e
1 changed files with 8 additions and 10 deletions
|
@ -58,7 +58,6 @@ AUTOUPDATE=no
|
||||||
AUTOSTART=no
|
AUTOSTART=no
|
||||||
CRON=no
|
CRON=no
|
||||||
QUIET=no
|
QUIET=no
|
||||||
SILENT=no
|
|
||||||
ARCH=$(uname -m)
|
ARCH=$(uname -m)
|
||||||
|
|
||||||
# Default options for package managers, override if needed
|
# Default options for package managers, override if needed
|
||||||
|
@ -156,7 +155,6 @@ usage() {
|
||||||
echo " -q Quiet mode. No stdout, only stderr and cronexit codes"
|
echo " -q Quiet mode. No stdout, only stderr and cronexit codes"
|
||||||
echo " -r Print download URL and exit"
|
echo " -r Print download URL and exit"
|
||||||
echo " -s Auto start (needed for some distros)"
|
echo " -s Auto start (needed for some distros)"
|
||||||
echo " -S Silent mode. No text output, only exit codes"
|
|
||||||
echo " -u Auto update plexupdate.sh before running it (experimental)"
|
echo " -u Auto update plexupdate.sh before running it (experimental)"
|
||||||
echo " -U Do not autoupdate plexupdate.sh (experimental, default)"
|
echo " -U Do not autoupdate plexupdate.sh (experimental, default)"
|
||||||
echo
|
echo
|
||||||
|
@ -185,7 +183,7 @@ do
|
||||||
(-q) QUIET=yes;;
|
(-q) QUIET=yes;;
|
||||||
(-r) PRINT_URL=yes;;
|
(-r) PRINT_URL=yes;;
|
||||||
(-s) AUTOSTART=yes;;
|
(-s) AUTOSTART=yes;;
|
||||||
(-S) SILENT=yes;;
|
(-S) echo "ERROR: SILENT option has been removed, please use QUIET (-q) instead" 1>&2; cronexit 1;;
|
||||||
(-u) AUTOUPDATE=yes;;
|
(-u) AUTOUPDATE=yes;;
|
||||||
(-U) AUTOUPDATE=no;;
|
(-U) AUTOUPDATE=no;;
|
||||||
(--) ;;
|
(--) ;;
|
||||||
|
@ -200,14 +198,14 @@ if [ "${KEEP}" = "yes" ]; then
|
||||||
cronexit 1
|
cronexit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# send all stdout to /dev/null
|
if [ "${SILENT}" = "yes" ]; then
|
||||||
if [ "${QUIET}" = "yes" ] || [ "${SILENT}" = "yes" ]; then
|
echo "ERROR: SILENT option has been removed, please use QUIET instead" >&2
|
||||||
exec 5>&1 >/dev/null
|
cronexit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# send all stdout and stderr to /dev/null
|
# send all stdout to /dev/null
|
||||||
if [ "${SILENT}" = "yes" ]; then
|
if [ "${QUIET}" = "yes" ]; then
|
||||||
exec 2> /dev/null
|
exec 5>&1 >/dev/null
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${AUTOUPDATE}" == "yes" ]; then
|
if [ "${AUTOUPDATE}" == "yes" ]; then
|
||||||
|
@ -435,7 +433,7 @@ if [ $? -ne 0 ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${PRINT_URL}" == "yes" ]; then
|
if [ "${PRINT_URL}" == "yes" ]; then
|
||||||
if [ "${QUIET}" = "yes" ] || [ "${SILENT}" = "yes" ]; then
|
if [ "${QUIET}" = "yes" ]; then
|
||||||
echo "${DOWNLOAD}" >&5
|
echo "${DOWNLOAD}" >&5
|
||||||
else
|
else
|
||||||
echo "${DOWNLOAD}"
|
echo "${DOWNLOAD}"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue